Re: Multiple update problem

From: Thomas Kyte <tkyte_at_us.oracle.com>
Date: Thu, 21 May 1998 16:01:25 GMT
Message-ID: <356a4f60.13724044_at_192.86.155.100>


I recommend you grab a hold of the Server Concepts Manual. It goes through all of this stuff at a pretty good level.

Its chapter 10 in the V7 doc set.
Its chapter 22 in the V8 doc set.

A copy of this was sent to Mungo Henning <mungoh_at_itacs.strath.ac.uk> (if that email address didn't require changing) On Thu, 21 May 1998 14:54:34 +0100, you wrote:

>Thomas Kyte wrote:
>
>> >[multiple update scenario snipped]
>>
>> Read consistency applies to Reads. Reads will not block in Oracle (unless of
>> course they are select ... for update which is similar to updating the data).
>>
>> In order to have consistent data in the database however, Writes may (and will
>> at times) block other writes. UserA is writing, UserB is writing -- UserA and
>> UserB may block eachother.
>Therefore would I be correct in concluding that the index for a table
>(I'm assuming
>that there's only one, but I know better than that) similarly has some
>locking
>mechanism applied to it to prevent two (or more) users from updating it
>at the same
>time?
>
>
>> No, the block would not be released until UserA commits. that is because UserA
>> 'owns' the row with the value 10, the row with the value 90 (that doesn't exist
>> anymore but does exist in reality -- it was there), and the row with the value
>> 80 -- they are all the same row -- UserA just owns all of the index entries
>> right now.
>>
>Is there high traffic on indexes then? Is it right to think that the
>index for
>record ten is marked as "unavailable" whilst userA is altering it to
>ninety?
>Further, if the user subsequently alters the deptno to eighty, we have
>two
>values in the index which reference "unavailable" records?
>
>Again, thanks in advance
>
>Mungo Henning
 

Thomas Kyte
tkyte_at_us.oracle.com
Oracle Government
Herndon VA  

http://govt.us.oracle.com/ -- downloadable utilities  



Opinions are mine and do not necessarily reflect those of Oracle Corporation  

Anti-Anti Spam Msg: if you want an answer emailed to you, you have to make it easy to get email to you. Any bounced email will be treated the same way i treat SPAM-- I delete it. Received on Thu May 21 1998 - 18:01:25 CEST

Original text of this message