Thread: predicate locking knowledge
Attached is a patch for the documentation. We currently state that we don't know of any production DBMS which uses predicate locking. Current versions of at least two commercial products (Sybase ASE and Microsoft SQL Server) do use it. I believe this has been true since 1990 or earlier. If people need documentation for this, I can pull something together. If you want quick confirmation, and you have access to either of the above products, just try the test case from the documentation page this patch modifies. Briefly, in these products no page is ever read or written without first acquiring a lock; in SERIALIZABLE mode all locks are held until COMMIT or ROLLBACK. Stating that we're not aware of it doesn't enhance our credibility with people using these products, who can easily confirm that the "contrived" example in our documentation does indeed generate a serialization error in their current product. There is also a chance, however slim, that we could lead someone into trouble with this statement. -Kevin
>>> On Thu, Mar 23, 2006 at 1:13 pm, in message <44229EE6.EE98.0025.0@wicourts.gov>, "Kevin Grittner" <Kevin.Grittner@wicourts.gov> wrote: Attachment didn't seem to go through. Embedding below. Index: mvcc.sgml =================================================================== RCS file: /projects/cvsroot/pgsql/doc/src/sgml/mvcc.sgml,v retrieving revision 2.55 diff -c -r2.55 mvcc.sgml *** mvcc.sgml 10 Mar 2006 19:10:48 -0000 2.55 --- mvcc.sgml 23 Mar 2006 18:58:13 -0000 *************** *** 471,477 **** result in problems. (Certainly the example above is rather contrived and unlikely to represent real software.) Accordingly, <productname>PostgreSQL</productname> does not implement predicate ! locking, and so far as we are aware no other production DBMS does either. </para> <para> --- 471,477 ---- result in problems. (Certainly the example above is rather contrived and unlikely to represent real software.) Accordingly, <productname>PostgreSQL</productname> does not implement predicate ! locking. </para> <para>
"Kevin Grittner" <Kevin.Grittner@wicourts.gov> writes: > Attached is a patch for the documentation. We currently state that we > don't know of any production DBMS which uses predicate locking. Current > versions of at least two commercial products (Sybase ASE and Microsoft > SQL Server) do use it. Are they actually doing fully-general predicate locks (able to cope with arbitrary predicate conditions), or merely index range locks? I don't mind expanding the docs, but the context of the statement is the cost of doing general predicate locking, and pointing to DBMSes that do a subset case doesn't make that statement invalid. regards, tom lane