Tom Lane wrote: > Log Message: > ----------- > Recognize functional dependency on primary keys. This allows a table's > other columns to be referenced without listing them in GROUP BY, so long as > the primary key column(s) are listed in GROUP BY. > > Eventually we should also allow functional dependency on a UNIQUE constraint > when the columns are marked NOT NULL, but that has to wait until NOT NULL > constraints are represented in pg_constraint, because we need to have > pg_constraint OIDs for all the conditions needed to ensure functional > dependency. > > Peter Eisentraut, reviewed by Alex Hunsaker and Tom Lane
Because of this commit, I am removing this "we do not want" TODO item: {{TodoItem |Indeterminate behavior for the GROUP BY clause (not wanted) |At least one other database product allows specification of a subset of the result columns which GROUP BY would need to be able to provide predictable results; the server is free to return any value from the group. This is not viewed as a desirable feature. * [http://archives.postgresql.org/pgsql-hackers/2010-03/msg00297.php <nowiki>Re: SQL compatibility reminder: MySQL vs PostgreSQL</nowiki>] }} My guess is our new 9.1 functionality will reduce requests for this features, so we can just not list it anymore. If they still ask, we can re-added this not-wanted item. -- Bruce Momjian <br...@momjian.us> http://momjian.us EnterpriseDB http://enterprisedb.com + It's impossible for everything to be true. + -- Sent via pgsql-hackers mailing list (pgsql-hackers@postgresql.org) To make changes to your subscription: http://www.postgresql.org/mailpref/pgsql-hackers