Skip to content

Commit 42f9de4

Browse files
Daniewrouesnel
authored andcommitted
Added pg_statio_user_tables
1 parent e2db729 commit 42f9de4

File tree

1 file changed

+34
-0
lines changed

1 file changed

+34
-0
lines changed

queries.yaml

Lines changed: 34 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -78,6 +78,40 @@ pg_stat_user_tables:
7878
- autoanalyze_count:
7979
usage: "COUNTER"
8080
description: "Number of times this table has been analyzed by the autovacuum daemon"
81+
82+
pg_statio_user_tables:
83+
query: "SELECT schemaname, relname, heap_blks_read, heap_blks_hit, idx_blks_read, idx_blks_hit, toast_blks_read, toast_blks_hit, tidx_blks_read, tidx_blks_hit FROM pg_statio_user_tables"
84+
metrics:
85+
- schemaname:
86+
usage: "LABEL"
87+
description: "Name of the schema that this table is in"
88+
- relname:
89+
usage: "LABEL"
90+
description: "Name of this table"
91+
- heap_blks_read:
92+
usage: "COUNTER"
93+
description: "Number of disk blocks read from this table"
94+
- heap_blks_hit:
95+
usage: "COUNTER"
96+
description: "Number of buffer hits in this table"
97+
- idx_blks_read:
98+
usage: "COUNTER"
99+
description: "Number of disk blocks read from all indexes on this table"
100+
- idx_blks_hit:
101+
usage: "COUNTER"
102+
description: "Number of buffer hits in all indexes on this table"
103+
- toast_blks_read:
104+
usage: "COUNTER"
105+
description: "Number of disk blocks read from this table's TOAST table (if any)"
106+
- toast_blks_hit:
107+
usage: "COUNTER"
108+
description: "Number of buffer hits in this table's TOAST table (if any)"
109+
- tidx_blks_read:
110+
usage: "COUNTER"
111+
description: "Number of disk blocks read from this table's TOAST table indexes (if any)"
112+
- tidx_blks_hit:
113+
usage: "COUNTER"
114+
description: "Number of buffer hits in this table's TOAST table indexes (if any)"
81115

82116
pg_database:
83117
query: " SELECT pg_database.datname, pg_database_size(pg_database.datname) as size FROM pg_database"

0 commit comments

Comments
 (0)