Re: Workaround: Planner preference for tsquery filter vs. GIN index in fast text search - Mailing list pgsql-performance

From Tom Lane
Subject Re: Workaround: Planner preference for tsquery filter vs. GIN index in fast text search
Date
Msg-id 26989.1398175110@sss.pgh.pa.us
Whole thread Raw
In response to Re: Workaround: Planner preference for tsquery filter vs. GIN index in fast text search  (Heikki Linnakangas <hlinnakangas@vmware.com>)
List pgsql-performance
Heikki Linnakangas <hlinnakangas@vmware.com> writes:
> On 04/20/2014 07:46 AM, Oleg Bartunov wrote:
>> btw, 9.4 should be wiser in case of rare+common terms, thanks to GIN
>> fast scan feature.

> Indeed, although we didn't actually do anything to the planner to make
> it understand when fast scan helps.

The given query has nothing to do with rare+common terms, since there is
only one term in the search --- and what's more, the planner's estimate
for that term is spot on already (755 estimated matches vs 752 actual).

It looks to me like the complaint is more probably about inappropriate
choice of join order; but since we've been allowed to see only some small
portion of either the query or the plan, speculating about the root cause
is a fool's errand.

            regards, tom lane


pgsql-performance by date:

Previous
From: Souquieres Adam
Date:
Subject: Query on partitioned table not using index
Next
From: Matthew Spilich
Date:
Subject: Re: Stalls on PGSemaphoreLock