"Jonah H. Harris" <[EMAIL PROTECTED]> writes: > My thinking is that we may be able to implement index usage for not only > unqualified counts, but also on any query that can be satisfied by the > index itself.
The fundamental problem is that you can't do it without adding at least 16 bytes, probably 20, to the size of an index tuple header. That would double the physical size of an index on a simple column (eg an integer or timestamp). The extra I/O costs and extra maintenance costs are unattractive to say the least. And it takes away some of the justification for the whole thing, which is that reading an index is much cheaper than reading the main table. That's only true if the index is much smaller than the main table ... regards, tom lane ---------------------------(end of broadcast)--------------------------- TIP 9: the planner will ignore your desire to choose an index scan if your joining column's datatypes do not match