Re: Query with high planning time at version 11.1 compared versions 10.5 and 11.0
Ashutosh Bapat <ashutosh.bapat.oss@gmail.com>
From: Ashutosh Bapat <ashutosh.bapat.oss@gmail.com>
To: alvherre@2ndquadrant.com
Cc: Langote_Amit_f8@lab.ntt.co.jp, pryzby@telsasoft.com,
sanyo.moura@tatic.net, Jeff Janes <jeff.janes@gmail.com>, david.rowley@2ndquadrant.com, Robert Haas <robertmhaas@gmail.com>, pgsql-performance@lists.postgresql.org, pgsql-hackers@postgresql.org
Date: 2018-12-07T11:14:14Z
Lists: pgsql-hackers, pgsql-performance
On Fri, Dec 7, 2018 at 11:13 AM Ashutosh Bapat <ashutosh.bapat.oss@gmail.com> wrote: > > > >> >> >> Robert, Ashutosh, any comments on this? I'm unfamiliar with the >> partitionwise join code. >> > > As the comment says it has to do with the equivalence classes being used > during merge append. EC's are used to create pathkeys used for sorting. > Creating a sort node which has column on the nullable side of an OUTER join > will fail if it doesn't find corresponding equivalence class. You may not > notice this if both the partitions being joined are pruned for some reason. > Amit's idea to make partition-wise join code do this may work, but will add > a similar overhead esp. in N-way partition-wise join once those equivalence > classes are added. > > > I looked at the patch. The problem there is that for a given relation, we will add child ec member multiple times, as many times as the number of joins it participates in. We need to avoid that to keep ec_member list length in check. -- Best Wishes, Ashutosh Bapat
Commits
-
Postpone generating tlists and EC members for inheritance dummy children.
- b10e3bba8673 11.2 landed
- 8d8dcead1295 12.0 landed
-
Allow direct lookups of AppendRelInfo by child relid
- 7d872c91a3f9 11.0 cited