Re: BUG #5968: DOCUMENTATION: SELECT synopsis omits RETURNING keyword

Поиск
Список
Период
Сортировка
От Gavin Flower
Тема Re: BUG #5968: DOCUMENTATION: SELECT synopsis omits RETURNING keyword
Дата
Msg-id 4D9ED3C1.6030103@archidevsys.co.nz
обсуждение исходный текст
Ответ на Re: BUG #5968: DOCUMENTATION: SELECT synopsis omits RETURNING keyword  (Tom Lane <tgl@sss.pgh.pa.us>)
Список pgsql-bugs
On 08/04/11 14:57, Tom Lane wrote:
> "Gavin Flower"<gavin.flower@archidevsys.co.nz>  writes:
>> I think the documentation of SELECT should include the keyword 'RETURNING'
>> in its synopsis.
> Huh?  There's no SELECT RETURNING.
>
>             regards, tom lane
The 'WITH' clause is described in the synopsis for 'SELECT' - and the
'WITH' clause uses the keyword 'RETURNING'.

and/with_query/  is:

     /with_query_name/  [ (/column_name/  [, ...] ) ] AS (/select/  |/insert/  |/update/  |/delete/  )


So as the 'WITH' clause is defined in the synopsis, I would expect that
the synopsis for 'SELECT' should also mention the 'RETURNING' keyword -
but it does not.

There is an example in:

'7.8. WITH Queries (Common Table Expressions)'

WITH t AS (
     UPDATE products SET price = price * 1.05
     RETURNING *
)
SELECT * FROM t;


Regards,
Gavin

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

Предыдущее
От: Gavin Flower
Дата:
Сообщение: Re: BUG #5968: DOCUMENTATION: SELECT synopsis omits RETURNING keyword
Следующее
От: Alvaro Herrera
Дата:
Сообщение: Re: Failed assert ((data - start) == data_size) in heaptuple.c