Received: from davinci.ethosmedia.com (davinci.ethosmedia.com [209.10.40.250]) by postgresql.org (Postfix) with ESMTP id 7A1F8475872 for ; Mon, 29 Apr 2002 01:24:54 -0400 (EDT) Received: from [63.195.55.98] (account ) by davinci.ethosmedia.com (CommuniGate Pro WebUser 3.5.9) with HTTP id 1387410; Sun, 28 Apr 2002 22:24:53 -0700 From: "Josh Berkus" Subject: Re: IN, EXISTS or ANY? To: Tom Lane , "Josh Berkus" Cc: pgsql-sql@postgresql.org X-Mailer: CommuniGate Pro Web Mailer v.3.5.9 Date: Sun, 28 Apr 2002 22:24:53 -0700 Message-ID: In-Reply-To: <17935.1020056063@sss.pgh.pa.us> MIME-Version: 1.0 Content-Type: text/plain; charset="ISO-8859-1" Content-Transfer-Encoding: 8bit X-Archive-Number: 200204/350 X-Sequence-Number: 7614 Tom, > But EXISTS is an entirely different animal which is often faster > ... isn't that in the FAQ? OK, still true, then hey? So for subqueries where I expect a medium-to-large result set, I should use EXISTS. Got it. BTW, just tried the new CURSOR implementation for PL/pgSQL for the first time. Nice work, guys! -Josh