Re: NOT-IN CLAUSE

From: Bruno Wolff III <bruno(at)wolff(dot)to>
To: Prashant Dalal <pdalal(at)laborlogix(dot)com>
Cc: pgsql-sql(at)postgresql(dot)org
Subject: Re: NOT-IN CLAUSE
Date: 2003-12-15 19:28:47
Message-ID: 20031215192847.GA24755@wolff.to
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-sql

On Mon, Dec 15, 2003 at 12:14:17 -0500,
Prashant Dalal <pdalal(at)laborlogix(dot)com> wrote:
> Hi,
>
> My Following select st. is running from last one day. I think the problem is
> NOT IN clause.
> Please suggest the alternative select clause.

NOT IN was especially slow up until Postgres 7.4. If using 7.4 is a problem
you can rewrite your query to use NOT EXISTS.

In response to

Browse pgsql-sql by date

  From Date Subject
Next Message Tom Lane 2003-12-16 03:55:38 Re: arrays in pl/pgsql
Previous Message Prashant Dalal 2003-12-15 17:14:17 NOT-IN CLAUSE