pg.ddx.io  pgsql-performance@postgresql.org mailing list archive  
help / color / mirror / Atom feed
From: Tom Lane <tgl@sss.pgh.pa.us>
To: Chris Hoover <revoohc@sermonaudio.com>
Cc: pgsql-performance@postgresql.org
Subject: Re: Use of subquery causes seq scan???
Date: Tue, 20 Apr 2004 17:58:31 -0400
Message-ID: <22627.1082498311@sss.pgh.pa.us> (raw)
In-Reply-To: <200404201020.05699.revoohc@sermonaudio.com>
References: <200404151248.16067.jeremy.guthrie@berbee.com>
	<200404201020.05699.revoohc@sermonaudio.com>

"Chris Hoover" <revoohc@sermonaudio.com> writes:
> Select *
> from table a
> where inv_num in (select inv_num from table b where ....)

> I'm running 7.3.4 on RedHat EL 2.1.

IN (SELECT) constructs pretty well suck in PG releases before 7.4.
Update, or consult the FAQ about rewriting into an EXISTS form.

			regards, tom lane



view thread (3+ messages)

Message-ID: <22627.1082498311@sss.pgh.pa.us>
Permalink:  ../22627.1082498311@sss.pgh.pa.us/
Also on:    postgresql.org/message-id/22627.1082498311@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 using the --to and --cc options:
  reply via email

  To: pgsql-performance@postgresql.org
  Cc: tgl@sss.pgh.pa.us, revoohc@sermonaudio.com
  Subject: Re: Use of subquery causes seq scan???
  In-Reply-To: <22627.1082498311@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