Subject: many deletes and inserts on pg_class, total rows is 14200 rows in "pg_class", any idea why so many inserts/deletes on "pg_class" it's self?

From: James Pang <[email-masked]>
Date: Tue, 24 Jun 2025 22:22:38 +0800

-[ RECORD 1 ]-------+------------------------------
relid               | 1259
schemaname          | pg_catalog
relname             | pg_class
seq_scan            | 22173212
seq_tup_read        | 153735849586
idx_scan            | 12471735164
idx_tup_fetch       | 12193538267
n_tup_ins           | 3604618       <<<hehre
n_tup_upd           | 617627
n_tup_del           | 3605790         <<< here
n_tup_hot_upd       | 566022
n_live_tup          | 14252
n_dead_tup          | 1257
n_mod_since_analyze | 52
n_ins_since_vacuum  | 1119
last_vacuum         | 2025-06-24 02:20:28.852129+00
last_autovacuum     | 2025-06-24 11:39:14.281472+00
last_analyze        | 2025-06-24 02:20:28.929375+00
last_autoanalyze    | 2025-06-24 14:15:53.545063+00
vacuum_count        | 367
autovacuum_count    | 24628
analyze_count       | 367
autoanalyze_count   | 8904

Thanks,

James

---

From: "David G. Johnston" <[email-masked]>
Date: Tue, 24 Jun 2025 07:31:12 -0700

You use temporary tables extensively.
David J.