B+ tree or B-tree
问题 I am learning about postgresql internals and I am wondering or postgresql B-tree index is actually classic B-tree or B+tree? To spell it out, that means the nodes contain only keys or key-value pairs? 回答1: B-trees. Only keys. The point of indexes is to store keys to begin with. Data lies in tables, which are logical heaps. Here is a related chapter on Wikipedia. The physical storage of B-tree indexes and tables is otherwise very similar. They use the same data pages with mostly the same page