Subject Re: [firebird-support] Creation of a "Replication Friendly" database. Any rules of thumb?
Author Joe Martinez
I am in the process of making my application multi-site right now with
replication (I'm writing my own replication server). I thought about doing
2-part primary keys, but a much more elegant solution is to use
GUID's. They are guaranteed to be unique, and don't require worrying about
colliding values, plus it's a single field.

-Joe


At 11:37 AM 3/23/2005, you wrote:
>acegracely wrote:
> >
> >
> > I need to make my database replication friendly...
> >
> > Am I right in thinking that the easiest way is to make all primary
> > keys an integer with a generator?
>
>That's a start.
> >
> > If so, will this fall over if replication is bi directional i.e.
> > depending on the time interval between replications, both ends could
> > add a number of records thus the generators could be out of sync.
>
>Yup. But put a table in your database that contains a field that
>identifies the server and make all your keys two part - server and
>generated value.