Oracle FAQ Your Portal to the Oracle Knowledge Grid
HOME | ASK QUESTION | ADD INFO | SEARCH | E-MAIL US
 

Home -> Community -> Usenet -> c.d.o.server -> Re: Row locking and serializability

Re: Row locking and serializability

From: Jonathan Lewis <jonathan_at_jlcomp.demon.co.uk>
Date: Wed, 7 Jul 1999 10:43:16 +0100
Message-ID: <931341362.28143.2.nnrp-02.9e984b29@news.demon.co.uk>

And this, I believe, is exactly the effect that appeared in Oracle 5 al the time, and appears in later versions if you set serializable = true. (which still seems to be there in 8.1.5 despite the documentation to the contrary !)

As iggy_fernandez has pointed out, the
Microsoft research paper by

    Berenson, Hal ; Bernstein, Phil ; Gray, Jim ;     Melton, Jim ; O'Neil, Elizabeth ; O'Neil, Patrick,     dated June 1995

makes comments to the effect that for
serializability, a database would need to use 'predicate' locks - i.e. a lock would have to be aquired on all possible rows that might be returned by a query EVEN IF they do not yet exist - so locking the entire table is probably the quick and easy route, so long as no-one else wants to use the database.

--

Jonathan Lewis
Yet another Oracle-related web site: www.jlcomp.demon.co.uk

Vadim Tropashko wrote in message <37826BD6.773C9C50_at_yahoo.com>...
>iggy_fernandez_at_my-deja.com wrote:
>
>> The question that remains unanswered is how
>> serializability may be manually achieved when
>> using Oracle.
>
>This one seems easy -- just lock "the whole" table:
>
>alter session set isolation_level=serializable;
>select * from passengers for update;
>insert into passengers values 'Z';
>commit;
>
>Thransaction above is serializable indeed.
>
Received on Wed Jul 07 1999 - 04:43:16 CDT

Original text of this message

HOME | ASK QUESTION | ADD INFO | SEARCH | E-MAIL US