returning does not act as expected after viewing documentation

From: PG Doc comments form <noreply(at)postgresql(dot)org>
To: pgsql-docs(at)lists(dot)postgresql(dot)org
Cc: lennartrolland(at)gmail(dot)com
Subject: returning does not act as expected after viewing documentation
Date: 2019-09-23 17:47:54
Message-ID: 156926087407.1118.10468521588901274687@wrigleys.postgresql.org
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-docs

The following documentation comment has been logged on the website:

Page: https://www.postgresql.org/docs/11/dml-returning.html
Description:

With the following query:

update batch_log
set status=('in-progress'),
updated_at=now()
where status = ('pending')
and id = (
select id
from batch_log
where status = ('pending')
order by priority desc, updated_at asc
limit 1
)
returning id, batch_log.update_at
;

I get the following error message:

column batch_log.update_at does not exist
LINE 14: returning id, batch_log.update_at
HINT: Perhaps you meant to reference the column "batch_log.updated_at".

This does not make a whole lot of sense. It is recommending that I do what I
am doing!

Also I don't see why this would fail.

I am on PostgreSQL 11 latest official docker image as of today's date
(2019-09-23).

Responses

Browse pgsql-docs by date

  From Date Subject
Next Message Umberto 2019-09-23 20:05:27 Re: invalid ldconfig [option]
Previous Message Tom Lane 2019-09-23 16:56:36 Re: @> (contains)