Hello,

Currently the documentation says that one can put "a list of table expressions"
after FROM in UPDATE or after USING in DELETE.
However, "table expression" is defined as a complex of
FROM, WHERE, GROUP BY and HAVING clauses [1].
The thing one can list in the FROM clause in a comma-separated manner
is called a table reference [2].
SELECT reference does not use this term but explains what they could be [3].

Please could someone have a look at the patch attached?
It's not just pedantry but rather based on a real-life example of someone reading and being not sure
whether e.g. joins can be used in there.

Best, Alex

[1] https://www.postgresql.org/docs/devel/queries-table-expressions.html
[2] https://www.postgresql.org/docs/devel/queries-table-expressions.html#QUERIES-FROM
[3] https://www.postgresql.org/docs/devel/sql-select.html#SQL-FROM
diff --git a/doc/src/sgml/ref/delete.sgml b/doc/src/sgml/ref/delete.sgml
index df8cea48cf..3f9e067b47 100644
--- a/doc/src/sgml/ref/delete.sgml
+++ b/doc/src/sgml/ref/delete.sgml
@@ -120,9 +120,9 @@ DELETE FROM [ ONLY ] <replaceable class="parameter">table_name</replaceable> [ *
     <term><replaceable class="parameter">using_list</replaceable></term>
     <listitem>
      <para>
-      A list of table expressions, allowing columns from other tables
+      A list of table references, allowing columns from other tables
       to appear in the <literal>WHERE</literal> condition.  This is similar
-      to the list of tables that can be specified in the <xref
+      to the list of tables or other sources that can be specified in the <xref
       linkend="sql-from" endterm="sql-from-title"/> of a
       <command>SELECT</command> statement; for example, an alias for
       the table name can be specified.  Do not repeat the target table
diff --git a/doc/src/sgml/ref/update.sgml b/doc/src/sgml/ref/update.sgml
index f58dcd8877..44815cc654 100644
--- a/doc/src/sgml/ref/update.sgml
+++ b/doc/src/sgml/ref/update.sgml
@@ -167,10 +167,10 @@ UPDATE [ ONLY ] <replaceable class="parameter">table_name</replaceable> [ * ] [
     <term><replaceable class="parameter">from_list</replaceable></term>
     <listitem>
      <para>
-      A list of table expressions, allowing columns from other tables
+      A list of table references, allowing columns from other tables
       to appear in the <literal>WHERE</literal> condition and the update
-      expressions. This is similar to the list of tables that can be
-      specified in the <xref linkend="sql-from"
+      expressions. This is similar to the list of tables or other sources
+      that can be specified in the <xref linkend="sql-from"
       endterm="sql-from-title"/> of a <command>SELECT</command>
       statement.  Note that the target table must not appear in the
       <replaceable>from_list</replaceable>, unless you intend a self-join (in which

Reply via email to