Re: [GENERAL] GROUP BY problem with 6.5

From: "Ross J(dot) Reedstrom" <reedstrm(at)wallace(dot)ece(dot)rice(dot)edu>
To: Tamas Nyitrai <defiant(at)telnet(dot)hu>
Cc: pgsql-general(at)postgresql(dot)org
Subject: Re: [GENERAL] GROUP BY problem with 6.5
Date: 1999-07-05 15:16:02
Message-ID: 19990705101602.A7939@wallace.ece.rice.edu
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-general

On Mon, Jul 05, 1999 at 02:01:11PM +0200, Tamas Nyitrai wrote:

<snipped a gentle rebuff to my earlier slightly high-handed post>

Tamas -
Sorry didn't mean to come across sounding short. Bruce's answer was just a
little ... succinct, since you had mentioned you had queries that used to
work, I thought I should mention _why_ the behavior changed. Then I got
carried away, imaging how people might repond to that.

As to lack of SQL knowledge in this regard, let me suggest you analyze
the queries that you are doing group by on, and only return the fields
you actually need grouped on (and the aggregates, of course.) in particular,
look out for constructs like 'SELECT foo.* ...' that wildcard is almost
never appropriate for a GROUP BY query.

HTH,
Ross
--
Ross J. Reedstrom, Ph.D., <reedstrm(at)rice(dot)edu>
NSBRI Research Scientist/Programmer
Computer and Information Technology Institute
Rice University, 6100 S. Main St., Houston, TX 77005

In response to

Browse pgsql-general by date

  From Date Subject
Next Message Maarten Boekhold 1999-07-05 15:37:56 Re: [GENERAL] Joins and links
Previous Message Bruce Momjian 1999-07-05 15:10:06 Re: [GENERAL] Joins and links