Please start any new threads on our new
site at https://forums.sqlteam.com. We've got lots of great SQL Server
experts to answer whatever question you can come up with.
Author |
Topic |
shahjugnu
Starting Member
1 Post |
Posted - 2012-04-14 : 06:47:27
|
Hello!I have a query regarding Merge Replication.I have 5 Tables.SetYarnMain Fields (MainId(PK), MainName, Comments)SetYarnSub (SubId(PK), SubName, MainId(FK), Comments)SetYarnDet (DetId(PK), DetName,SubId(FK),MainId(FK), Comments)SetYarnGrp (GrpId(PK), GrpName, DetId(FK),SubId(FK),MainId(FK), Comments)SetYarn (YarnId(PK),YarnName,GrpId(FK),DetId(FK),SubId(FK),MainId(FK),Comments)These Tables doesnt have Identity Column and PK are of char datatypeLets take 2 tables SetYarnMain and SetYarnSub. I am generating a series in SetYarnSub Table with respect to SetYarnMain Table.Let say MainId is 01 at Location A and at Location B.If a user at Location B Inserts a row the SubId let say becomes 01001, but If a user at Location A Inserts a row then same Id is generated because the replication hasn't done yet.When merge replication is performed table SetYarnSub at both location has 01001 id creates conflict in PK.I need to know how to solve this problem.Please if someone has the solution I humbly request to post it immediately.Thanks and RegardsShahJugnu |
|
|
|
|
|
|