0

I am using merge replication in SQL 2012. Some of my merge articles use column level tracking.

I am trying to understand how to use the 'lineage', and 'colv1' fields in the MSmerge_contents table to work out which columns have changed in a particular row in my database.

1 Answer 1

1

You can use sp_showlineage and sp_showcolv to inspect the lineage and columns that have been changed. The sp_showcolv results contain a column, colidx, which is the index of the column(s) that were changed for a given version of the row.

If you need to take a more proactive approach, you can setup an auditing scheme. I've provided an example of how to setup an auditing scheme on my blog: http://www.sqlrepl.com/sql-server/auditing-changes-in-merge-replication/

1
  • Auditing scheme. Yeah that might be necessary too. Very handy.
    – peter
    Nov 2, 2012 at 3:08

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.