none
does merge replication physically add the row guid to the publisher side? RRS feed

  • Question

  • ...if yes, isnt this a problem if the publisher side is a 3rd party product that perhaps has select *'s in it?  we run 2017 std.
    Wednesday, August 21, 2019 5:00 PM

All replies

  • A column of type RowGuid in the table(s) is mandatory for merge replication and no one of us can say how your 3rd Party would react on such a new column; ask the Software vendor instead.

    Olaf Helper

    [ Blog] [ Xing] [ MVP]


    Thursday, August 22, 2019 6:37 AM
  • Hi db042190,

    >>does merge replication physically add the row guid to the publisher side?

    If you are creating your own GUID key you have to ensure that it will generate different values on the publisher and subscriber. Otherwise when the merge agent runs and does the synchronization it will try to insert a GUID value from the subscriber into the publisher which already has this value. The insert attempt will fail as the PK guarantees uniqueness of values.

    Best regards,
    Cathy

    MSDN Community Support
    Please remember to click "Mark as Answer" the responses that resolved your issue, and to click "Unmark as Answer" if not. This can be beneficial to other community members reading this thread. If you have any compliments or complaints to  MSDN Support, feel free to contact MSDNFSF@microsoft.com

    Thursday, August 22, 2019 7:52 AM
  • thx Cathy and Olaf so i'm concluding from your responses that its (the scenario where sql generates the guid automatically) a physical column, not something like a non persisted column. 

    That is unacceptable for our 3rd party product.

    And I'm a little surprised because merge replication was suggested in this forum as an alternative to tran replication on tables that don't have a pk.  But Cathy's post references a pk.  That is somewhat confusing.  Does that mean that merge replication also  makes the guid it generates automatically in some scenarios a  pk.  The documentation suggests that sql server creates the guid column in some circumstances automatically.  I have to reread it but I concluded that was on both the publisher and subscriber side.


    • Edited by db042190 Thursday, August 22, 2019 3:14 PM clarity
    Thursday, August 22, 2019 2:33 PM