Re: SKIP LOCKED DATA (work in progress)

Поиск
Список
Период
Сортировка
От Simon Riggs
Тема Re: SKIP LOCKED DATA (work in progress)
Дата
Msg-id CA+U5nMJtJBmaV-XAmbB+eFuAvzopO0=iNaWMN143qQnD0H6AdA@mail.gmail.com
обсуждение исходный текст
Ответ на Re: SKIP LOCKED DATA (work in progress)  (Tom Lane <tgl@sss.pgh.pa.us>)
Ответы Re: SKIP LOCKED DATA (work in progress)
Re: SKIP LOCKED DATA (work in progress)
Список pgsql-hackers
On 23 May 2014 10:40, Tom Lane <tgl@sss.pgh.pa.us> wrote:

> If we're pulling syntax out of the air it'd be nice if we could avoid
> adding new keywords to the grammar.

Oracle, SQLServer and DB2 have this capability. MySQL does not.

SQLServer implements that using the table hint of READPAST. Since that
whole syntax area is radically different to what we have, it isn't
easy to maintain code compatibility.

DB2 z/OS 10 provides SKIP LOCKED DATA clause to allow moving past
already locked rows. That's fairly recent and I don't believe there
will be many programs using that. DB2 UDB supports some complex
functionality using DB2_SKIPINSERTED, DB2_EVALUNCOMMITTED and
DB2_SKIPDELETED, all of which is complex and mostly exists for
benchmarks, AFAICS.

Oracle uses both SKIP LOCKED and NOWAIT.

PostgreSQL already chose to follow the Oracle syntax when we
implemented NOWAIT. So my proposal is that we follow the Oracle syntax
again and use the words SKIP LOCKED.

I don't see any advantage in inventing new syntax that leaves us
incompatible with Oracle, nor do I see any need to be compatible with
both Oracle and DB2 since the latter is much less likely to gain us
anything in practice.

-- Simon Riggs                   http://www.2ndQuadrant.com/PostgreSQL Development, 24x7 Support, Training & Services



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

Предыдущее
От: Bruce Momjian
Дата:
Сообщение: Re: 9.4 release notes
Следующее
От: Pavel Stehule
Дата:
Сообщение: Re: SKIP LOCKED DATA (work in progress)