Excerpts from Greg Stark's message of lun abr 18 15:47:03 -0300 2011:
> A lot of SQL queries end up being written with GROUP BY primary_key,
> other_column, other_column, other_column just to get those other
> columns to be queryable. If we implemented the SQL standard
> "dependent" columns feature this would be unnecessary but we don't and
> even if we did people would still build schemas and queries that
> defeat the optimization.
Actually we do have that in 9.1. It's a bit more restrictive than
really required (there are some more cases we could handle), but AFAIR
at least the primary key is handled now.
--
Álvaro Herrera <alvherre@commandprompt.com>
The PostgreSQL Company - Command Prompt, Inc.
PostgreSQL Replication, Consulting, Custom Development, 24x7 support