Oracle FAQ | Your Portal to the Oracle Knowledge Grid |
![]() |
![]() |
Home -> Community -> Mailing Lists -> Oracle-L -> RE: shared database sequence.
Would this work?
A really simple, not so elegant solution would be to have a sequence generator on each database
DB#1 start with 1 increment by 2 (generates only odd sequence numbers) DB#2 start with 2 increment by 2 (generates only even sequence numbers)
From: oracle-l-bounce_at_freelists.org [mailto:oracle-l-bounce_at_freelists.org]
On Behalf Of Mark W. Farnham
Sent: Monday, February 26, 2007 10:47 AM
To: sjaffarhussain_at_gmail.com; 'oracle-l'
Subject: RE: shared database sequence.
Do you just need uniqueness or do you need some correspondence amongst the databases?
If so, how chunky can the correspondence be?
If the database servers are reliably near each other in a network latency sense you would still have to decide whether the network latency of using a dblink to get sequence numbers from a different database is acceptable.
If you don't need a correspondence, then you can maintain uniqueness by assigning something like a database number to each database and tacking a suffix on, so for example all the ids from database 3 end in 3.
mwf
From: oracle-l-bounce_at_freelists.org [mailto:oracle-l-bounce_at_freelists.org]
On Behalf Of Syed Jaffar Hussain
Sent: Monday, February 26, 2007 4:14 AM
To: oracle-l
Subject: shared database sequence.
Hello List,
Is it possible to share a database sequence between multiple databases? Not in RAC of course.
We are planning to have two databses exchanging information (replicating) using third party solution. But, stuck with the issues of sequences.
Thanks
-- Best Regards, Syed Jaffar Hussain Oracle ACE 8i,9i & 10g OCP DBA http://jaffardba.blogspot.com/ <http://jaffardba.blogspot.com/> http://www.oracle.com/technology/community/oracle_ace/ace1.html#hussain <http://www.oracle.com/technology/community/oracle_ace/ace1.html#hussain> ---------------------------------------------------------------------------- ------ "Winners don't do different things. They do things differently." -- http://www.freelists.org/webpage/oracle-lReceived on Mon Feb 26 2007 - 12:59:26 CST
![]() |
![]() |