Re: BUG #14404: High row estimates when query uses master inherited tables - Mailing list pgsql-bugs

From Tom Lane
Subject Re: BUG #14404: High row estimates when query uses master inherited tables
Date
Msg-id 25623.1478116390@sss.pgh.pa.us
Whole thread Raw
In response to Re: BUG #14404: High row estimates when query uses master inherited tables  (Tom Lane <tgl@sss.pgh.pa.us>)
List pgsql-bugs
I wrote:
> Ah.  So this must be something to do with the foreign-key-driven rowcoun=
t
> estimates we added in 9.6.  Will look into it, thanks for the report!

I think the answer is that we failed to consider inheritance cases at all
while developing the aforementioned logic.  For the moment, I've
band-aided this by disabling the FK estimation logic when either relation
is an inheritance parent.  If you need a patch immediately, see

https://git.postgresql.org/gitweb/?p=3Dpostgresql.git;a=3Dcommitdiff;h=3D2=
3c6c437f98c996092c0adfad6152d9cc699c8b0

            regards, tom lane

pgsql-bugs by date:

Previous
From: Tom Lane
Date:
Subject: Re: BUG #14404: High row estimates when query uses master inherited tables
Next
From: Sandeep Thakkar
Date:
Subject: Re: Compilation of timezone source with zic fails (on mountpoint)