FIX: The Number of Parameters Does Not Match Error Message From Distribution Task (299287)



The information in this article applies to:

  • Microsoft SQL Server 2000 Enterprise Edition
  • Microsoft SQL Server 2000 Standard Edition
  • Microsoft SQL Server 2000 Developer Edition

This article was previously published under Q299287
BUG #: 354026 (SHILOH_BUGS)

SYMPTOMS

When you use a Data Transformation Services (DTS) package to transform data from a publisher to a subscriber, the following error message may be generated by the Distribution Agent if an update operation is performed on the publisher:
The number of parameters in the replication command does not match what is defined in the DTS package. Regenerate the package.
This error message only occurs if there is a composite primary key defined on the published table. The error message does not require you to re-create the DTS package.

CAUSE

When an update is performed on the published tables, the Logreader Agent generates a CALL command to the sp_MSUpd_Tablename stored procedure. If the table that is updated contains a composite primary key, an incorrect number of parameters are passed to the update stored procedure, which causes the error message to occur.

RESOLUTION

To resolve this problem, obtain the latest service pack for Microsoft 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, modify the publication and enable the Provide support for horizontal partitions created by DTS Transformation Scripts option for each article in the publication that has a composite primary key. You can enable the option from the Table Articles Properties dialog box under Publication Properties. After you enable the option on the publication, all the existing subscriptions must be dropped and re-created.

STATUS

Microsoft has confirmed this to be a problem in SQL Server 2000. This problem was first corrected in Microsoft SQL Server 2000 Service Pack 2.

Modification Type:MinorLast Reviewed:7/15/2004
Keywords:kbBug kbfix KB299287