Re: cannot get stable function to use index

From: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
To: Andy Colson <andy(at)squeakycode(dot)net>
Cc: pgsql <pgsql-general(at)postgresql(dot)org>
Subject: Re: cannot get stable function to use index
Date: 2015-12-30 16:09:50
Message-ID: 13146.1451491790@sss.pgh.pa.us
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-general

Andy Colson <andy(at)squeakycode(dot)net> writes:
> -> Bitmap Index Scan on search_key (cost=0.00..6.00 rows=1 width=0) (actual time=0.025..0.025 rows=0 loops=1)
> Index Cond: (search_vec @@ to_tsquery('213 & E & 13 & ST & N'::text))

Hmm ... so the partial case actually is significantly more expensive than
the non-partial case: 4 msec vs .025 msec. Still, that's about a 200x
penalty, not the 10000x penalty the planner is ascribing to it.

Thanks for the data! I'll go moan about this on -hackers.

regards, tom lane

In response to

Responses

Browse pgsql-general by date

  From Date Subject
Next Message Andy Colson 2015-12-30 18:02:27 Re: cannot get stable function to use index
Previous Message Andy Colson 2015-12-30 16:02:01 Re: cannot get stable function to use index