postgres/contrib/file_fdw
Robert Haas f2bae51dfd Keep track of what RTIs a Result node is scanning.
Result nodes now include an RTI set, which is only non-NULL when they
have no subplan, and is taken from the relid set of the RelOptInfo that
the Result is generating. ExplainPreScanNode now takes notice of these
RTIs, which means that a few things get schema-qualified in the
regression tests that previously did not. This makes the output more
consistent between cases where some part of the plan tree is replaced by
a Result node and those where this does not happen.

Likewise, pg_overexplain's EXPLAIN (RANGE_TABLE) now displays the RTIs
stored in a Result node just as it already does for other RTI-bearing
node types.

Result nodes also now include a result_reason, which tells us something
about why the Result node was inserted.  Using that information, EXPLAIN
now emits, where relevant, a "Replaces" line describing the origin of
a Result node.

The purpose of these changes is to allow code that inspects a Plan
tree to understand the origin of Result nodes that appear therein.

Discussion: http://postgr.es/m/CA+TgmoYeUZePZWLsSO+1FAN7UPePT_RMEZBKkqYBJVCF1s60=w@mail.gmail.com
Reviewed-by: Alexandra Wang <alexandra.wang.oss@gmail.com>
Reviewed-by: Richard Guo <guofenglinux@gmail.com>
Reviewed-by: Tom Lane <tgl@sss.pgh.pa.us>
Reviewed-by: Junwang Zhao <zhjwpku@gmail.com>
2025-09-23 09:07:55 -04:00
..
data file_fdw: Add REJECT_LIMIT option to file_fdw. 2024-11-20 23:53:19 +09:00
expected Keep track of what RTIs a Result node is scanning. 2025-09-23 09:07:55 -04:00
sql Disallow "=" in names of reloptions and foreign-data options. 2025-06-02 15:22:44 -04:00
.gitignore Support "make check" in contrib 2011-04-25 22:27:11 +03:00
file_fdw--1.0.sql Throw a useful error message if an extension script file is fed to psql. 2011-10-12 15:45:03 -04:00
file_fdw.c Use PRI?64 instead of "ll?" in format strings (continued). 2025-03-29 10:43:57 +01:00
file_fdw.control
Makefile Remove dynamic translation of regression test scripts, step 2. 2021-12-20 14:15:52 -05:00
meson.build Update copyright for 2025 2025-01-01 11:21:55 -05:00