Tom Lane <mailto:t...@sss.pgh.pa.us> writes:
> Bill Martin writes:
>> Tom Lane writes:
>>> He can do it without having to change his schema --- but it's the
>>> index column, not the underlying content column, that needs its
>>> statistics targe
> Tom Lane writes:
> He can do it without having to change his schema --- but it's the index
> column, not the underlying content column, that needs its statistics
> target adjusted.
> regards, tom lane
How can I adjust the statistics target of the index?
--
Sent via p
> Tom Lane writes:
>> Bill Martin writes:
>> I've tried different values for the statistics but it is all the same (the
>> planner decide to switch to a seqscan if the limit is 10).
>> ALTER TABLE core_content ALTER column content SET STATISTICS 1000;
>
Tom Lane writes:
> Bill Martin writes:
>> I´ve created following table which contains one million records.
>> ...
>> "Limit (cost=10091.09..19305.68 rows=3927 width=621) (actual
>> time=0.255..0.255 rows=0 loops=1)"
>> " -> Bitmap Heap Sca
(actual
time=52147.149..52147.149 rows=0 loops=1)"
" -> Seq Scan on core_content content (cost=0.00..98384.34 rows=20011
width=621) (actual time=52147.147..52147.147 rows=0 loops=1)"
"Filter: (to_tsvector('simple'::regconfig, content) @@
'''asdasdadas'':*'::tsquery)"
"Total runtime: 52147.173 ms"
Is there any posibility to tune up the performance even if the limit is only
10? Is it possible to determine that the query optimizer takes
only the fast bitmap heap scan instead of the slow seq scan?
I use PostgreSQL 9.1.5.; Intel i5-2400 @ 3.1 GHz, 16GB; Windows 7 64 Bit
Regards,
Bill Martin