Re: [PATCH] Error out if SKIP LOCKED and WITH TIES are both specified

Alvaro Herrera <alvherre@alvh.no-ip.org>

From: Alvaro Herrera <alvherre@alvh.no-ip.org>
To: David Christensen <david.christensen@crunchydata.com>
Cc: PostgreSQL-development <pgsql-hackers@postgresql.org>
Date: 2021-08-30T20:51:27Z
Lists: pgsql-hackers

Attachments

On 2021-Aug-13, David Christensen wrote:

> Both bugs #16676[1] and #17141[2] illustrate that the combination of
> SKIP LOCKED and FETCH FIRST WITH TIES break expectations when it comes
> to rows returned to other sessions accessing the same row.  Since this
> situation is detectable from the syntax and hard to fix otherwise,
> forbid for now, with the potential to fix in the future.

I think we should do this, given that it has show potential to bite
people.  We should also add a small mentioned to this in the docs, as in
the attached.

What do others think?

-- 
Álvaro Herrera              Valdivia, Chile  —  https://www.EnterpriseDB.com/
"Escucha y olvidarás; ve y recordarás; haz y entenderás" (Confucio)

Commits

  1. Error out if SKIP LOCKED and WITH TIES are both specified