Merge Replication - native exception

Hi!

Here are the details:

- Merge replication is set up between SQL Server 2000 SP3 <-> SQL CE clients

- It is expected for the system to have 100-150 PDA users

- About 80-90 tables are being replicated. About half of the tables are for documents  that PDA users create. These tables have to be filtered by SUSER_SNAME() to minimize data transfered and not to allow users to see each others documents. For filtering we used join filters (now there is about 30-40 join filters)

- Tables shared by users have GUID primary key, while other tables have identity columns.

System seemed to work fine when number of tables and number of join filters was about half that it is now.

Now, occasionally we get Native exception 0x00000005 on the PDA after calling Synchronize method of the C# Replication object. Data is transfered to the server, but the application hangs.

In the documentation for SQL Server it is mentioned that performance may suffer from too many join filters so this may be the cause of our problem.

If this is source of the problem one solution would be to use simple horizontal filtering on all tables now included in the join filters (and to add username field to all these tables). We could also reduce number of join filters with denormalisation (which we are not inclined to do).

Any other suggestions Is our assumption about the source of the error corect

Can anyone give us some recommendations for database metrics (number of constraints, tables, join filters etc) that can (or do) work with sql ce merge replication.

Thanks!



Answer this question

Merge Replication - native exception

  • Minneapolis

    First thing is to determine the source of the exception - is this an exception from the device, agent, or sql server   are there any dump files generated anywhere
  • Daenris

     

    On this link you will find two posts relating to the idetical problem (without a solution)...

    http://www.dotnet247.com/247reference/msgs/49/245603.aspx

    I think I have misinterpreted the article - its not the SQL server corrupting the snapshot! Exception is raised when some rows change partition (which, again didn't happen!).

    Conflict tables in the database are all empty. When I try to get list of the conflicts using enterprise manager (right click on publication, view conflicts) I get "unexpected error occured while trying to launch the Conflict viewer". 


  • invalid

     Davor Cokrlic wrote:

     In meanwhile i have done some research and found that this error (native exception 0xc0000005 during merge process) is caused by SQL server somehow corrupting merge partitions.

    I've never heard of this, can you point me to where you read this information   If SQL Server was actually "corrupting" something, merge agent would surely fail, which you said wasn't happening.

     Davor Cokrlic wrote:

    SqlCeReplication object on the PDA instead of reporting that there has been a integrity violation in the database throws this exception.

    Are you saying that when the agent is uploading changes, it's getting PK/FK constraint violations   Is this what you see when you look at the conflicts at the publisher


  • Vitor Hervatin

    If the synchronization process is causing an access violation, you should contact customer support to get the hotfix.  This should fix the access violation and return the true error.  Once you get the error, post it here if you still have any questions, as it may not be the same error in the post.
  • old ken

     

    There really aren't any log/dump files that I know of that could point to the problem. Evene the SQL server reports that replication succeded (that can be seen on the list of merge agents in Enterprise Manager).

    In meanwhile i have done some research and found that this error (native exception 0xc0000005 during merge process) is caused by SQL server somehow corrupting merge partitions.

    SqlCeReplication object on the PDA instead of reporting that there has been a integrity violation in the database throws this exception.

    Do you know anything about this There is a patch that enables the PDA to report real error (of which i could not find a download) but even this patch does not prevent SQL server from messing-up.

    Any real solutions/pointers


  • Merge Replication - native exception