Subject: pgsql: Prohibit locking clauses on GRAPH_TABLE

From: Peter Eisentraut <[email-masked]>
Date: Thu, 09 Jul 2026 08:16:34 +0000

Prohibit locking clauses on GRAPH_TABLE

Specifying a locking clause (FOR UPDATE/SHARE) that names a
GRAPH_TABLE alias currently results in an unhelpful "unrecognized RTE
type: 8" error.  This commit explicitly prohibits specifying a locking
clause on a GRAPH_TABLE alias, raising a more user-friendly error
instead.

(Locking clause support for GRAPH_TABLE could be added as a separate
feature in the future.)

Author: SATYANARAYANA NARLAPURAM <[email-masked]>
Author: Ayush Tiwari <[email-masked]>
Reviewed-by: Ashutosh Bapat <[email-masked]>
Discussion: https://www.postgresql.org/message-id/flat/CAHg%2BQDcE9wp6nOEC3SCRQ90nrCO%3DQF%2BOZq1MG8Qc6hnusmogqw%40mail.gmail.com

Branch
------
REL_19_STABLE

Details
-------
https://git.postgresql.org/pg/commitdiff/01c544e1afb99bc2a76803870010b7cd2907f3b5

Modified Files
--------------
src/backend/parser/analyze.c              |  9 +++++++++
src/test/regress/expected/graph_table.out | 13 +++++++++++++
src/test/regress/sql/graph_table.sql      |  4 ++++
3 files changed, 26 insertions(+)