From 1f4f4c87550af4065b85830b35079ec930779877 Mon Sep 17 00:00:00 2001 From: "David G. Johnston" Date: Thu, 9 Jun 2022 15:15:52 +0000 Subject: [PATCH] doc: Clarify that excluded is really just a special name --- doc/src/sgml/ref/insert.sgml | 13 ++++++------- 1 file changed, 6 insertions(+), 7 deletions(-) diff --git a/doc/src/sgml/ref/insert.sgml b/doc/src/sgml/ref/insert.sgml index a9af9959c0..0fad1d3640 100644 --- a/doc/src/sgml/ref/insert.sgml +++ b/doc/src/sgml/ref/insert.sgml @@ -175,9 +175,8 @@ INSERT INTO table_name [ AS table_name. When an alias is provided, it completely hides the actual name of the table. This is particularly useful when ON CONFLICT DO UPDATE - targets a table named excluded, since that will otherwise - be taken as the name of the special table representing rows proposed - for insertion. + targets a table named excluded, since that will + conflict with the special name representing the row proposed for insertion. @@ -396,8 +395,8 @@ INSERT INTO table_name [ AS SET and WHERE clauses in ON CONFLICT DO UPDATE have access to the existing row using the - table's name (or an alias), and to rows proposed for insertion - using the special excluded table. + table's name (or an alias), and to the proposed row + using the name excluded. SELECT privilege is required on any column in the target table where corresponding excluded columns are read. @@ -699,8 +698,8 @@ INSERT INTO employees_log SELECT *, current_timestamp FROM upd; Insert or update new distributors as appropriate. Assumes a unique index has been defined that constrains values appearing in the - did column. Note that the special - excluded table is used to reference values originally + did column. Note that the name + excluded is used to reference values originally proposed for insertion: INSERT INTO distributors (did, dname) -- 2.25.1