| From: | Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us> |
|---|---|
| To: | "Guillaume Smet" <guillaume(dot)smet(at)gmail(dot)com> |
| Cc: | pgsql-performance <pgsql-performance(at)postgresql(dot)org> |
| Subject: | Re: Estimation problem with a LIKE clause containing a / |
| Date: | 2007-11-07 16:34:52 |
| Message-ID: | 17767.1194453292@sss.pgh.pa.us |
| Views: | Whole Thread | Raw Message | Download mbox | Resend email |
| Thread: | |
| Lists: | pgsql-hackers pgsql-performance |
"Guillaume Smet" <guillaume(dot)smet(at)gmail(dot)com> writes:
> [ bad estimate for LIKE ]
Hmmm ... what locale are you working in? I notice that the range
estimator for this pattern would be "ancestors >= '1062/' AND
ancestors < '10620'", which will do the right thing in C locale
but maybe not so much elsewhere.
> Version is PostgreSQL 8.1.8 on i686-redhat-linux-gnu,
You'd probably get better results with 8.2, which has a noticeably
smarter LIKE-estimator, at least for histogram sizes of 100 or more.
regards, tom lane
| From | Date | Subject | |
|---|---|---|---|
| Next Message | Guillaume Smet | 2007-11-07 16:52:16 | Re: Estimation problem with a LIKE clause containing a / |
| Previous Message | Jacques Caron | 2007-11-07 16:18:29 | pg_statistic "forced" values |
| From | Date | Subject | |
|---|---|---|---|
| Next Message | Guillaume Smet | 2007-11-07 16:52:16 | Re: Estimation problem with a LIKE clause containing a / |
| Previous Message | Kevin Grittner | 2007-11-07 16:32:15 | Re: index stat |