Quantcast
Channel: SQL Server Replication forum
Viewing all articles
Browse latest Browse all 4054

Merge replication : Give indication on client to inform data is uploaded to publisher

$
0
0

Hi,

we use merge replication to synchronize sales data. The publisher/distributor is a SQL2012 standard edition, the subscribers are SQL2012 express editions. We are using pull subscriptions.
Orders are created on the clients and are initiated with a status 'No upload to publisher'.
The salesperson can check the orders for upload in his application which gives the orders the status 'Upload to publisher'.
The merge process synchronises the order records (ignoring the status). 
So the status is more a functional setting, no influence on the merge process.
We tried to make a trigger on the order table on the publisher which fires on insert and for the records with status 'Upload to publisher' we change the status to 'uploaded to publisher' (these records cannot be changed anymore on the subscriber, this is checked in the application).
We already set this trigger to fire first and last (before or after the merge triggers). 
Sometimes this works ok, sometimes it does not, resulting in a failed data validation  (rowcount and checksum), in which case the rowcount is correct, but the checksum is not.

Is there a way to make this reliable ? (I would not like to change the validation to rowcount only.)


Viewing all articles
Browse latest Browse all 4054

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>