On 23 May 2014 10:40, Tom Lane <t...@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 -- Sent via pgsql-hackers mailing list (pgsql-hackers@postgresql.org) To make changes to your subscription: http://www.postgresql.org/mailpref/pgsql-hackers