Re: UPDATE mentions the RETURNING * syntax but does not mention RETURNING * INTO ...

From: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
To: James Stuart <slim2k(at)privatejuris(dot)org>
Cc: pgsql-bugs(at)lists(dot)postgresql(dot)org
Subject: Re: UPDATE mentions the RETURNING * syntax but does not mention RETURNING * INTO ...
Date: 2023-09-04 21:00:13
Message-ID: 1198351.1693861213@sss.pgh.pa.us
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-bugs

James Stuart <slim2k(at)privatejuris(dot)org> writes:
> UPDATE mentions the RETURNING * syntax but does not mention RETURNING *
> INTO ...

> https://www.postgresql.org/docs/15/sql-update.html

That's because there is no such thing so far as the core SQL parser is
concerned (so if you try it from, say, psql, it won't work).

There is such syntax in plpgsql, and that's where it's documented:

https://www.postgresql.org/docs/current/plpgsql-statements.html#PLPGSQL-STATEMENTS-SQL-ONEROW

regards, tom lane

In response to

Browse pgsql-bugs by date

  From Date Subject
Next Message David Rowley 2023-09-04 21:12:47 Re: BUG #18084: Count Mismatch Challenges During PostgreSQL Database Migration: Causes and Solutions
Previous Message PG Bug reporting form 2023-09-04 17:55:51 BUG #18084: Count Mismatch Challenges During PostgreSQL Database Migration: Causes and Solutions