Re: ANTI-JOIN needs table, index scan not possible?

From: "Kevin Grittner" <Kevin(dot)Grittner(at)wicourts(dot)gov>
To: "hans wulf" <lotu1(at)gmx(dot)net>,"Kenneth Marshall" <ktm(at)rice(dot)edu>
Cc: <pgsql-performance(at)postgresql(dot)org>, "Maciek Sakrejda" <msakrejda(at)truviso(dot)com>
Subject: Re: ANTI-JOIN needs table, index scan not possible?
Date: 2011-03-11 22:32:03
Message-ID: 4D7A4E83020000250003B7E1@gw.wicourts.gov
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-performance

Kenneth Marshall <ktm(at)rice(dot)edu> wrote:
> On Fri, Mar 11, 2011 at 06:54:39PM +0100, hans wulf wrote:
>> so there's no way around this problem? A nice index bitmap merge
>> thing would be super fast. Big table ANTI JOIN queries with only
>> a few results expected, are totally broken, if this is true.
>>
>> This way the query breaks my neck. This is a massive downside of
>> postgres which makes this kind of query impossible. Mysql gives
>> you the answer in a few seconds :-(
>
> Super! I am glad that MySQL can meet your needs. No software is
> perfect and you should definitely chose based on your use-case.

Well, as far as I can see we haven't yet seen near enough
information to diagnose the issue, suggest alternative ways to write
the query which might perform better, or determine whether there's
an opportunity to improve the optimizer here.

Hans, please read this page and provide more detail:

http://wiki.postgresql.org/wiki/SlowQueryQuestions

-Kevin

In response to

Browse pgsql-performance by date

  From Date Subject
Next Message John Surcombe 2011-03-12 10:07:41 Planner wrongly shuns multi-column index for select .. order by col1, col2 limit 1
Previous Message Kenneth Marshall 2011-03-11 22:16:03 Re: ANTI-JOIN needs table, index scan not possible?