Hi,
We changed our replication system from SQL 2008 R2 to SQL 2017. This means we installed SQL 2017 developer edition with the latest CU on a brand new server. The subscriber remained on SQL 2008 R2. I recreated for the merge replication all subscriptions and everything is working like a charm.
But on one new laptop I installed SQL 2017 devlpr and created also the subscription. If I look on the subscriber the Synchronization Status, the replication is starting and after 30 minutes I get the message:
"The merge process could not replicate one or more INSERT statements to the 'subscriber'.
A stored procedure fails to execute. Troubleshoot by using SQL Profiler."
I looked in the profiler:
2018-10-01 12:08:19.439 The merge process is retrying a failed operation made to article 'TTable' - Reason: 'A query executing on Subscriber 'LAPTOP-W10\TEMP' failed because the connection was chosen as the victim in adeadlock. Please rerun the merge process if you still see this error after internal retries by the merge process.'.
2018-10-01 12:08:19.439 OLE DB Distributor 'SERVER-SQL\TEMP2017': {call sys.sp_MSadd_merge_history90 (?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?)}
2018-10-01 12:08:19.439 The merge process could not replicate one or more INSERT statements to the 'Subscriber'. A stored procedure failed to execute. Troubleshoot by using SQL Profiler.
2018-10-01 12:08:19.441 The merge process could not replicate one or more UPDATE statements to the 'Subscriber' because a stored procedure failed to execute. Troubleshoot by using SQL Profiler.
So it seems to be a Deadlock - but I don't understand why?
There is also nothing special with this table. I also took the database from another laptop (so the database should be up to date) - but same problem here.
Anything changed in SQL 2017 replication?
Any ideas?
Patrick