Re: Small docs bugfix: make it clear what can be used in UPDATE FROMand DELETE USING

Поиск
Список
Период
Сортировка
От David G. Johnston
Тема Re: Small docs bugfix: make it clear what can be used in UPDATE FROMand DELETE USING
Дата
Msg-id CAKFQuwZv_d7L3WQn+ZMORCATFL-MkKLjWhFf6uEtKvXTJUg55w@mail.gmail.com
обсуждение исходный текст
Ответ на Small docs bugfix: make it clear what can be used in UPDATE FROM andDELETE USING  (Alexey Bashtanov <bashtanov@imap.cc>)
Ответы Re: Small docs bugfix: make it clear what can be used in UPDATE FROM and DELETE USING  (Tom Lane <tgl@sss.pgh.pa.us>)
Список pgsql-hackers
On Thu, Feb 13, 2020 at 4:13 AM Alexey Bashtanov <bashtanov@imap.cc> wrote:
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

Drive-by comment - I'm on board with the idea but I do not believe this patch accomplishes the goal.

IMO there is too much indirection happening and trying to get terms exactly right, so the user can find or remember them from elsewhere in the documentation, doesn't seem like the best solution.  The material isn't that extensive and since it is covered elsewhere a little bit more explicitness in the DELETE and FROM documentation seems like a better path forward.

David J.

В списке pgsql-hackers по дате отправления:

Предыдущее
От: Fabrízio de Royes Mello
Дата:
Сообщение: Re: Bug in pg_restore with EventTrigger in parallel mode
Следующее
От: David Fetter
Дата:
Сообщение: Re: Small docs bugfix: make it clear what can be used in UPDATE FROMand DELETE USING