Microsoft KB Archive/305066

= FIX: Merge Agent Access Violation Occurs with Large Batch Size and Several Columns =

Article ID: 305066

Article Last Modified on 10/16/2003

-

APPLIES TO


 * Microsoft SQL Server 2000 Standard Edition

-



This article was previously published under Q305066



BUG #: 354575 (SHILOH_BUGS)



SYMPTOMS
The Merge Agent may encounter an access violation when the following conditions are met:
 * The article contains a large number of columns.
 * The following settings are set to high values:


 * -UploadReadChangesPerBatch
 * -DownloadReadChangesPerBatch
 * -UploadWriteChangesPerBatch
 * -DownloadWriteChangesPerBatch

When the access violation occurs, the Merge Agent fails and it's status in the Replication Monitor is marked as failed. No error message is generated in the Merge Agent output file. Depending on the default debugger configurationon on the computer that is running SQL Server, a .dmp or Dr. Watson log file may be generated.

The conditions in which the access violation occurs are not tied to specific values for these parameters, nor is it seen for specific numbers of columns in an article. Instead, it is a function of the number of columns in the article and the changes per the preceding batch settings.



CAUSE
A problem in the SQL Server ODBC driver prevents the binding of a high number of parameters with the SQLBindParameter function. The number of parameters that are bound are a direct function of the number of columns in the article and the number of changes that are sent in a batch.



RESOLUTION
To resolve this problem, obtain the latest service pack for SQL Server 2000. For additional information, click the following article number to view the article in the Microsoft Knowledge Base:

290211 INF: How to Obtain the Latest SQL Server 2000 Service Pack



WORKAROUND
To work around the problem, lower the values of the parameters in the &quot;Symptoms&quot; section to their default values of 100. For more information about the Merge Agent profile parameters and their default values, refer to the the &quot;Merge Agent Profile&quot; topic in SQL Server 2000 Books Online.



STATUS
Microsoft has confirmed that this is a problem in SQL Server 2000. This problem was first corrected in Microsoft SQL Server 2000 Service Pack 2.

Keywords: kbbug kbfix KB305066

-

[mailto:TECHNET@MICROSOFT.COM Send feedback to Microsoft]

© Microsoft Corporation. All rights reserved.