3
1 DR. GIRIJA NARASIMHAN Part 10 - Concurrently using same sequence by multi user

Part 10 concurrently same sequence by multi user

  • Upload
    hct

  • View
    81

  • Download
    1

Embed Size (px)

Citation preview

Page 1: Part 10 concurrently same sequence by multi user

1DR. GIRIJA NARASIMHAN

Part 10 - Concurrently using same sequence

by multi user

Page 2: Part 10 concurrently same sequence by multi user

2DR. GIRIJA NARASIMHAN

create sequence seq1START WITH 6INCREMENT BY 1NOCACHEmaxvalue 9minvalue 6cycle;

When a sequence number is generated, the sequence is incremented, independent of the transaction committing or rolling back. If two users concurrently increment the same sequence, then the sequence numbers each user acquires may have gaps, because sequence numbers are being generated by the other user.

One user can never acquire the sequence number generated by another user. After a sequence value is generated by one user, that user can continue to access that value regardless of whether the sequence is incremented by another user.

Page 3: Part 10 concurrently same sequence by multi user

3DR. GIRIJA NARASIMHAN