Search Postgresql Archives

Re: Index is not used for "IN (non-correlated subquery)"

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

 



George <pinkisntwell@xxxxxxxxx> writes:
> On Thu, Dec 1, 2016 at 6:58 PM, Tom Lane <tgl@xxxxxxxxxxxxx> wrote:
>> What
>> do you get for
>> select * from pg_stats where tablename = 'wg3ppbm_userpartner';
>> and likewise for wg3ppbm_partner?

> It is a wide table. Do you want me to dump csv here?

Shouldn't be *that* wide, with only one row in the underlying table ;-)
Maybe psql \x format would be suitable.

> In the meantime, with the help of the folks at #postgresql I was able
> to wisen up the query planner by using either one of the following two
> settings:
>  SET enable_seqscan = false
>  SET cpu_tuple_cost = 0.1

Well, that proves it is considering the indexscan option.  But there is
something funny going on, if you have stats for these tables and yet
you're getting a default rowcount estimate.

			regards, tom lane


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



[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Index of Archives]     [Postgresql Jobs]     [Postgresql Admin]     [Postgresql Performance]     [Linux Clusters]     [PHP Home]     [PHP on Windows]     [Kernel Newbies]     [PHP Classes]     [PHP Books]     [PHP Databases]     [Postgresql & PHP]     [Yosemite]
  Powered by Linux