B-trees in PostgreSQL (cont)
Changes for PostgreSQL v12
- indexes smaller
- for composite keys, only store first attribute
- index entries are smaller, so ci larger, so tree shallower
- include TID in index key
- duplicate index entries are stored in "table order"
- makes scanning table files to collect results more efficient
To explore indexes in more detail:
-
\di+ IndexName
-
select * from bt_page_items(IndexName,BlockNo)
|