summaryrefslogtreecommitdiff
path: root/src/include/nodes/parsenodes.h
diff options
context:
space:
mode:
authorTom Lane <tgl@sss.pgh.pa.us>2023-01-11 22:56:34 -0500
committerTom Lane <tgl@sss.pgh.pa.us>2023-01-11 23:01:22 -0500
commitf0e6d6d3c909e14eedd370dd77d7111c2ae24c02 (patch)
tree70ef8e8249e7d43e5f46f66a1d6a8446b5b10f33 /src/include/nodes/parsenodes.h
parent5a26c7b310b629f8893483cc3cce5bbfa7879115 (diff)
Revert "Get rid of the "new" and "old" entries in a view's rangetable."
This reverts commit 1b4d280ea1eb7ddb2e16654d5fa16960bb959566. It's broken the buildfarm members that run cross-version-upgrade tests, because they're not prepared to deal with cosmetic differences between CREATE VIEW commands emitted by older servers and HEAD. Even if we had a solution to that, which we don't, it'd take some time to roll it out to the affected animals. This improvement isn't valuable enough to justify addressing that problem on an emergency basis, so revert it for now.
Diffstat (limited to 'src/include/nodes/parsenodes.h')
-rw-r--r--src/include/nodes/parsenodes.h18
1 files changed, 5 insertions, 13 deletions
diff --git a/src/include/nodes/parsenodes.h b/src/include/nodes/parsenodes.h
index f39ab8586a5..cfeca96d532 100644
--- a/src/include/nodes/parsenodes.h
+++ b/src/include/nodes/parsenodes.h
@@ -1009,6 +1009,11 @@ typedef struct RangeTblEntry
/*
* Fields valid for a plain relation RTE (else zero):
*
+ * As a special case, RTE_NAMEDTUPLESTORE can also set relid to indicate
+ * that the tuple format of the tuplestore is the same as the referenced
+ * relation. This allows plans referencing AFTER trigger transition
+ * tables to be invalidated if the underlying table is altered.
+ *
* rellockmode is really LOCKMODE, but it's declared int to avoid having
* to include lock-related headers here. It must be RowExclusiveLock if
* the RTE is an INSERT/UPDATE/DELETE/MERGE target, else RowShareLock if
@@ -1023,19 +1028,6 @@ typedef struct RangeTblEntry
* perminfoindex is 1-based index of the RTEPermissionInfo belonging to
* this RTE in the containing struct's list of same; 0 if permissions need
* not be checked for this RTE.
- *
- * As a special case, relid, rellockmode, and perminfoindex can also be
- * set (nonzero) in an RTE_SUBQUERY RTE. This occurs when we convert an
- * RTE_RELATION RTE naming a view into an RTE_SUBQUERY containing the
- * view's query. We still need to perform run-time locking and permission
- * checks on the view, even though it's not directly used in the query
- * anymore, and the most expedient way to do that is to retain these
- * fields from the old state of the RTE.
- *
- * As a special case, RTE_NAMEDTUPLESTORE can also set relid to indicate
- * that the tuple format of the tuplestore is the same as the referenced
- * relation. This allows plans referencing AFTER trigger transition
- * tables to be invalidated if the underlying table is altered.
*/
Oid relid; /* OID of the relation */
char relkind; /* relation kind (see pg_class.relkind) */