By using db<>fiddle, you agree to license everything you submit by Creative Commons CC0.
Help with an interesting Postgres question: Why isn't an Index Only Scan used on a partition accessed via the parent table?.
CREATE TABLE
metric | bytes/ct | bytes_pretty | bytes_per_row |
---|---|---|---|
core_relation_size | 0 | 0 bytes | null |
visibility_map | 0 | 0 bytes | null |
free_space_map | 0 | 0 bytes | null |
table_size_incl_toast | 0 | 0 bytes | null |
indexes_size | 8192 | 8192 bytes | null |
total_size_incl_toast_and_indexes | 8192 | 8192 bytes | null |
live_rows_in_text_representation | null | null | null |
------------------------------ | null | null | null |
row_count | 0 | null | null |
live_tuples | 0 | null | null |
dead_tuples | 0 | null | null |
SELECT 11
INSERT 0 2
metric | bytes/ct | bytes_pretty | bytes_per_row |
---|---|---|---|
core_relation_size | 8192 | 8192 bytes | 4096 |
visibility_map | 0 | 0 bytes | 0 |
free_space_map | 0 | 0 bytes | 0 |
table_size_incl_toast | 8192 | 8192 bytes | 4096 |
indexes_size | 16384 | 16 kB | 8192 |
total_size_incl_toast_and_indexes | 24576 | 24 kB | 12288 |
live_rows_in_text_representation | 176 | 176 bytes | 88 |
------------------------------ | null | null | null |
row_count | 2 | null | null |
live_tuples | 0 | null | null |
dead_tuples | 0 | null | null |
SELECT 11
size_on_disk | id | content_id | type | size | timestamp1 | timestamp2 |
---|---|---|---|---|---|---|
64 | 1 | aaa | bbb | 100 | 2022-09-19 06:32:44.712235 | 2022-09-19 06:32:44.712235 |
88 | 2 | aaaaaaaaaaaaa | bbbbbbbbbbbbbb | 100000000000 | 2022-09-19 06:32:44.712235 | 2022-09-19 06:32:44.712235 |
SELECT 2
content_id_size_on_disk | content_id_size_in_ram | content_id |
---|---|---|
4 | 7 | aaa |
14 | 17 | aaaaaaaaaaaaa |
SELECT 2