Replication

  • Hello Guys,

    Can anyone say whether two way replication is possible for tables having IDENTITY SET ON

    e.g.

    TableA

    ID INT NOT NULL IDENTITY(1,1) NOT FOR REPLICATION PRIMARY KEY, NAME VARCHAR(100)

    Can I setup a Two way replication for such tables i.e. If I make a change(Insert/Update/Delete) on Server1, the same change is reflected in Server2 and vice-versa.

    If this is possible, please suggest how to do.

  • Merge replication will handle it for you. If you want to do it yourself, basically have to assign a set of keys to each server so that you don't have conflicts, when replication does the insert it turns the identity insert off for the duration of the transaction.

    Andy

    http://qa.sqlservercentral.com/columnists/awarren/

Viewing 2 posts - 1 through 1 (of 1 total)

You must be logged in to reply to this topic. Login to reply