Re: Planner selects different execution plans depending on limit

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Jesper Krogh <jesper@xxxxxxxx> writes:
> On 13/09/12 16:42, Bill Martin wrote:
>> Yes, I've run the ANALYZE command. Regards, Bill Martin 

> The main problem in your case is actually that you dont store the 
> tsvector in the table.

Oh, duh, obviously I lack caffeine this morning.

> If you store to_tsvector('simple',content.content) in a column in
> the database and search against that instead
> then you'll allow PG to garther statistics on the column and make the
> query-planner act according to that.

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


-- 
Sent via pgsql-performance mailing list (pgsql-performance@xxxxxxxxxxxxxx)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-performance


[Postgresql General]     [Postgresql PHP]     [PHP Users]     [PHP Home]     [PHP on Windows]     [Kernel Newbies]     [PHP Classes]     [PHP Books]     [PHP Databases]     [Yosemite]

  Powered by Linux