0

I am looking for a way to get a unique ID per database itself. The idea is to exchange objects between different installations of my application. Therefore I have unique IDs for all objects within a single database, but in order to exchange these objects to other databases with the same schema, I introduced a composite ID consisting of a primary and a secondary ID, where the primary is unique within a single database and the secondary should be unique across multiple databases with the same schema.

Does somebody knows a decentralized solution for this issue?

salocinx
  • 3,715
  • 8
  • 61
  • 110
  • http://stackoverflow.com/questions/8180019/what-is-the-replacement-for-uniqueidentifier-in-mysql – Donal Aug 21 '14 at 10:06

1 Answers1

0

Using a global unique identifier for each row solves the problem. Java itself provides a UUID generator, but there are more (better) third-party generators as well.

salocinx
  • 3,715
  • 8
  • 61
  • 110