pg.ddx.io  pgsql-sql@postgresql.org mailing list archive  
help / color / mirror / Atom feed
From: Tom Lane <tgl@sss.pgh.pa.us>
To: omid omoomi <oomoomi@hotmail.com>
Cc: pgsql-general@postgresql.org
Cc: pgsql-sql@postgresql.org
Subject: Re: Aggregates and joined tables...
Date: Sun, 04 Feb 2001 23:06:33 -0500
Message-ID: <7954.981345993@sss.pgh.pa.us> (raw)
In-Reply-To: <LAW-F90itmyGLttMbUs000025fa@hotmail.com>
References: <LAW-F90itmyGLttMbUs000025fa@hotmail.com>

"omid omoomi" <oomoomi@hotmail.com> writes:
> The platform is PostgreSQL 6.5.2 on i386-unknown-freebsd3.2, compiled by gcc 
> 2.7.2.1 .

> I want to write a query which looks like this :
> select fa1 - sum(fc3)
> from A,B,C
> where fa1=fb1 and fb2=fc2
> group by fa1 ;
> unfortunately I get this in result:
> ERROR:  Illegal use of aggregates or non-group column in target list

Works fine in current sources.  Try upgrading to something newer than
6.5.2 ...

			regards, tom lane



view thread (3+ messages)

Message-ID: <7954.981345993@sss.pgh.pa.us>
Permalink:  ../7954.981345993@sss.pgh.pa.us/
Also on:    postgresql.org/message-id/7954.981345993@sss.pgh.pa.us

 · 

reply

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Reply to all the recipients from your mail client; the link fills in
  the headers below: reply via email
  Some clients, webmail especially, drop In-Reply-To and References from
  a link, and the reply then starts a new thread: use the mbox below.

  To: pgsql-sql@postgresql.org
  Cc: tgl@sss.pgh.pa.us, oomoomi@hotmail.com, pgsql-general@postgresql.org
  Subject: Re: Aggregates and joined tables...
  In-Reply-To: <7954.981345993@sss.pgh.pa.us>
  References: <LAW-F90itmyGLttMbUs000025fa@hotmail.com> <7954.981345993@sss.pgh.pa.us>

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

This inbox is served by DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox