Re: PG choosing nested loop for set membership?

From: Brian Crowell <brian(at)fluggo(dot)com>
To: David Johnston <polobo(at)yahoo(dot)com>
Cc: "pgsql-general(at)postgresql(dot)org >> PG-General Mailing List" <pgsql-general(at)postgresql(dot)org>
Subject: Re: PG choosing nested loop for set membership?
Date: 2014-03-25 21:21:46
Message-ID: CAAQkdDoaUB5JfN4SgKqWbhwXGXeb6BmaQxLNibXAYxnbgtwe_Q@mail.gmail.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-general

On Tue, Mar 25, 2014 at 4:12 PM, David Johnston <polobo(at)yahoo(dot)com> wrote:
> 2 - and the one I'd use by default) Use an INNER JOIN

That's where I started, but Postgres is smart enough to know that this
is equivalent to what I'm doing, and still picks the nested loop. I
went to IN in the hopes of tricking it.

I haven't tried EXISTS. I'll have to try that tomorrow.

--Brian

In response to

Browse pgsql-general by date

  From Date Subject
Next Message John Smith 2014-03-25 21:33:52 Re: tsearch2: how to plainto_tsquery() with "|"
Previous Message Brian Crowell 2014-03-25 21:17:42 Re: PG choosing nested loop for set membership?