Re: Documentation does not cover multiple WITH in one query

From: Bruce Momjian <bruce(at)momjian(dot)us>
To: KES <kes-kes(at)yandex(dot)ru>
Cc: "pgsql-docs(at)lists(dot)postgresql(dot)org" <pgsql-docs(at)lists(dot)postgresql(dot)org>
Subject: Re: Documentation does not cover multiple WITH in one query
Date: 2018-08-26 13:15:00
Message-ID: 20180826131500.GA26015@momjian.us
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-docs

On Sun, Aug 26, 2018 at 12:08:15PM +0300, KES wrote:
>
> Thank you. That is I am looking for.
> Never thought that 'WITH' syntax is described at 'SELECT'.
>
> Will be very helpful if this will be mentioned on this page: https://www.postgresql.org/docs/10/static/queries-with.html
> For an example:
>
> [ WITH [ RECURSIVE ] with_query [, ...] ]
>
> and with_query is shown as:
>
> with_query_name [ ( column_name [, ...] ) ] AS ( select | values | insert | update | delete )
>
> For full syntax of `WITH` see https://www.postgresql.org/docs/10/static/sql-select.html

There is are no syntax layouts on this page or in similar sections in
the docs --- they are reserved for the reference pages. I don't think
it makes sense to add it here. One odd thing is that WITH can be used
with non-SELECT statements, but we only document it in SELECT, which is
odd. I think that is because the SQL standard only uses WITH with
SELECT.

--
Bruce Momjian <bruce(at)momjian(dot)us> http://momjian.us
EnterpriseDB http://enterprisedb.com

+ As you are, so once was I. As I am, so you will be. +
+ Ancient Roman grave inscription +

In response to

Browse pgsql-docs by date

  From Date Subject
Next Message Justin Pryzby 2018-08-27 16:23:37 remove duplicated words in comments .. across lines
Previous Message Milivoj Ivkovic 2018-08-26 11:00:17 Re: 25.3. Continuous Archiving : Unix examples with Windows-style variables %-$