Re: working around JSONB's lack of stats?

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

 



On Tue, Jan 27, 2015 at 1:06 AM, Josh Berkus <josh@xxxxxxxxxxxx> wrote:
> Folks,
>
> Currently, JSONB fields don't have statistics, and estimate a flat 1%
> selectivity.  This can result in poor query plans, and I'm wondering if
> anyone has a suggested workaround for this short of hacking a new
> selectivity function.  For example, take the common case of using JSONB
> to hold a list of "tags" for tagging documents:

hm,  Why stop at jsonb?  What's needed is a way to override the
planner's row estimate in a general way.

merlin


-- 
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