Can 2 DB's share a common record ID?

  • Thread starter Thread starter Ted Stilwell
  • Start date Start date
T

Ted Stilwell

I have 2 manufacturing databases that are duplicates of each other. Each has
a table of records for mfg runs with an autonumber RunID. I would like to
ensure that the same RunID is assigned only once between the 2 databases.
For instance if database A has issued RunID #34065 then database B would not
be able to issue that same number. The second line has only recently come
into existence and there is substantial legacy programming for the earlier
line. What strategy can I use? Many thanks in advance and Merry Christmas.
 
I have 2 manufacturing databases that are duplicates of each other. Each has
a table of records for mfg runs with an autonumber RunID. I would like to
ensure that the same RunID is assigned only once between the 2 databases.
For instance if database A has issued RunID #34065 then database B would not
be able to issue that same number. The second line has only recently come
into existence and there is substantial legacy programming for the earlier
line. What strategy can I use? Many thanks in advance and Merry Christmas.

The best strategy I can think of is to give each database an ID (ie. 1
or 2) and prefix your auto-generated IDs with this. Then if both
databases generate the same autoID, the prefix makes it distinct and
unique.

Merry Christmas,
James
 
I have 2 manufacturing databases that are duplicates of each other. Each has
a table of records for mfg runs with an autonumber RunID. I would like to
ensure that the same RunID is assigned only once between the 2 databases.
For instance if database A has issued RunID #34065 then database B would not
be able to issue that same number. The second line has only recently come
into existence and there is substantial legacy programming for the earlier
line. What strategy can I use? Many thanks in advance and Merry Christmas.

FYI, I do this for POS transaction so every terminal has an ID to
prefix autogen'd IDs and thus save me from replication hell. Works
pretty well!
 
Thanks. I'll try that during shutdown
--
Ted


Minton M said:
FYI, I do this for POS transaction so every terminal has an ID to
prefix autogen'd IDs and thus save me from replication hell. Works
pretty well!
 
Back
Top