Received: from localhost (postgresql.org [64.49.215.8]) by postgresql.org (Postfix) with ESMTP id 5604747616F for ; Wed, 23 Oct 2002 11:51:15 -0400 (EDT) Received: from serwer.skawsoft.com.pl (serwer.skawsoft.com.pl [213.25.37.66]) by postgresql.org (Postfix) with ESMTP id 827C9475FDE for ; Wed, 23 Oct 2002 11:51:14 -0400 (EDT) Received: from lamer.pl (localhost [127.0.0.1]) by serwer.skawsoft.com.pl (Postfix) with ESMTP id 2381E2B4D8; Wed, 23 Oct 2002 17:44:45 +0200 (CEST) From: "Tomasz Myrta" To: Stephan Szabo , Tomasz Myrta Cc: Subject: Re: sub-select with aggregate Date: Wed, 23 Oct 2002 17:44:45 +0900 Message-Id: <20021023174445.M37904@klaster.net> In-Reply-To: <20021023081036.M5349-100000@megazone23.bigpanda.com> References: <3DB6B7F7.2030609@klaster.net> <20021023081036.M5349-100000@megazone23.bigpanda.com> X-Mailer: Open WebMail 1.62 20020221 X-OriginatingIP: 217.96.97.138 (jasiek) MIME-Version: 1.0 Content-Type: text/plain; charset=iso-8859-2 X-Virus-Scanned: by AMaViS new-20020517 X-Archive-Number: 200210/300 X-Sequence-Number: 10017 > On Wed, 23 Oct 2002, Tomasz Myrta wrote: > > > Uz.ytkownik Stephan Szabo napisa?: > Without group_id in the select list you couldn't do a where > group_id = if the select was a view. I know - it was just example of query. > Did you see the other two queries I gave? On 7.3, both of those queries > appear (according to explain output) to do the limiting of group_id > inside the subquery rather than doing the subquery with all rows. > The explanation above was why I believe it was different from your > original query. I saw them. So should I wait for 7.3? Currently I have 7.2 and my work stopped because of this. Tomasz Myrta