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

Home -> Community -> Mailing Lists -> Oracle-L -> RE: shared database sequence.

RE: shared database sequence.

From: Bobak, Mark <Mark.Bobak_at_il.proquest.com>
Date: Mon, 26 Feb 2007 11:50:27 -0500
Message-ID: <AA29A27627F842409E1D18FB19CDCF270B6B56B4@AABO-EXCHANGE02.bos.il.pqe>


I prefer:
Create sequence my_seq_in_database_1 start with 1 increment by 2; Create sequence my_seq_in_database_2 start with 2 increment by 2;

That way, you don't have to pick some preset upper limit, and you will never get a collision.

If you want the flexibility of adding other sources in the future, you could increment by 10, above. That way, you could add up to eight more sequences in the future.

Hope that helps,

-Mark

--
Mark J. Bobak
Senior Oracle Architect
ProQuest/CSA

"Gentlemen, it is time to stop tuning SQL and start tuning users."
--Bill "Shrek" Thater, Oracle DBA

-----Original Message-----
From: oracle-l-bounce_at_freelists.org
[mailto:oracle-l-bounce_at_freelists.org] On Behalf Of Gints Plivna
Sent: Monday, February 26, 2007 11:05 AM
To: sjaffarhussain_at_gmail.com
Cc: oracle-l
Subject: Re: shared database sequence.

In case you need not to get overlapping values you can simply define one
sequence with values starting from 1 to very big number and the other
from the very big number till very big number * 2 Or the other with just
start with -1 increment by -1

Of the overlapping sequences is not the case, then what is the problem?

Gints Plivna
http://www.gplivna.eu


2007/2/26, Syed Jaffar Hussain <sjaffarhussain_at_gmail.com>:

> 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. -- http://www.freelists.org/webpage/oracle-l -- http://www.freelists.org/webpage/oracle-l
Received on Mon Feb 26 2007 - 10:50:27 CST

Original text of this message

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