postgresql/contrib/postgres_fdw
Tom Lane e8d5dd6be7 Get rid of duplicate child RTE for a partitioned table.
We've been creating duplicate RTEs for partitioned tables just
because we do so for regular inheritance parent tables.  But unlike
regular-inheritance parents which are themselves regular tables
and thus need to be scanned, partitioned tables don't need the
extra RTE.

This makes the conditions for building a child RTE the same as those
for building an AppendRelInfo, allowing minor simplification in
expand_single_inheritance_child.  Since the planner's actual processing
is driven off the AppendRelInfo list, nothing much changes beyond that,
we just have one fewer useless RTE entry.

Amit Langote, reviewed and hacked a bit by me

Discussion: https://postgr.es/m/9d7c5112-cb99-6a47-d3be-cf1ee6862a1d@lab.ntt.co.jp
2019-03-26 12:03:27 -04:00
..
expected Get rid of duplicate child RTE for a partitioned table. 2019-03-26 12:03:27 -04:00
sql Suppress Append and MergeAppend plan nodes that have a single child. 2019-03-25 15:42:35 -04:00
.gitignore Add postgres_fdw contrib module. 2013-02-21 05:27:16 -05:00
connection.c Update copyright for 2019 2019-01-02 12:44:25 -05:00
deparse.c Renaming for new subscripting mechanism 2019-02-01 12:50:32 -03:00
Makefile Prevent accidental linking of system-supplied copies of libpq.so etc. 2018-04-03 16:26:05 -04:00
option.c Update copyright for 2019 2019-01-02 12:44:25 -05:00
postgres_fdw--1.0.sql Add postgres_fdw contrib module. 2013-02-21 05:27:16 -05:00
postgres_fdw.c Use slots in trigger infrastructure, except for the actual invocation. 2019-02-26 20:31:38 -08:00
postgres_fdw.control Add postgres_fdw contrib module. 2013-02-21 05:27:16 -05:00
postgres_fdw.h Rename nodes/relation.h to nodes/pathnodes.h. 2019-01-29 16:49:25 -05:00
shippable.c Update copyright for 2019 2019-01-02 12:44:25 -05:00