FIX: Replication: Problems Mapping Characters to DB2 OLEDB Subscribers

Article translations Article translations
Article ID: 239458 - View products that this article applies to.
This article was previously published under Q239458
BUG #: 55057,55058,55480 (SQLBUG_70)
Expand all | Collapse all


While replicating to subscribers running DB2 using the Microsoft OLEDB provider, certain datatypes are mapped incorrectly and nullability is not preserved. Also, when replicating to DB2 subscribers on MVS systems, the distribution agent fails with this error:
A SQL error has occurred. Please consult the documentation for your specific DB2 version for a description of the associated Native Error and SQL State.
The value of the input variable or parameter is invalid or too large for the target column or target value.


A supported hotfix is available from Microsoft. However, this hotfix is intended to correct only the problem that is described in this article. Apply this hotfix only to systems that are experiencing this specific problem.

If the hotfix is available for download, there is a "Hotfix download available" section at the top of this Knowledge Base article. If this section does not appear, submit a request to Microsoft Customer Service and Support to obtain the hotfix.

Note If additional issues occur or if any troubleshooting is required, you might have to create a separate service request. The usual support costs will apply to additional support questions and issues that do not qualify for this specific hotfix. For a complete list of Microsoft Customer Service and Support telephone numbers or to create a separate service request, visit the following Microsoft Web site:
Note The "Hotfix download available" form displays the languages for which the hotfix is available. If you do not see your language, it is because a hotfix is not available for that language. The English version of this fix should have the following file attributes or later:
   File name   Platform

   s70722i.exe  Intel
   s70722a.exe  Alpha
NOTE: Due to file dependencies, the most recent hotfix or feature that contains the above files may also contain additional files.


Microsoft has confirmed this to be a problem in SQL Server 7.0.


Specific symptoms encountered due to this bug are:
  • If the publisher column was defined with NOT NULL, the subscriber table was created to allow NULLs.
  • VARCHAR datatypes (variable length) are mapped to CHAR (fixed length) datatypes on the subscriber.
  • The script file that contains the CREATE TABLE SQL statement being generated by the replication engine contains TAB characters that the DB2 subscriber on MVS was unable to handle. This results in the error with SQLCODE: -601 and SQLSTATE: 42710
  • Problems with binding in the OLEDB provider where if the source type is a CHAR datatype, then the scale of the destination column is supplied incorrectly in bytes instead of characters. The DB2 subscriber on MVS does strict checking on the parameter column length to verify that it is less or equal to the defined column length in the table. This results in the error with SQLCODE: -302 and SQLSTATE: 22001.


Article ID: 239458 - Last Review: October 5, 2005 - Revision: 1.6
  • Microsoft SQL Server 7.0 Standard Edition
kbautohotfix kbhotfixserver kbbug kbfix kbqfe KB239458

Give Feedback


Contact us for more help

Contact us for more help
Connect with Answer Desk for expert help.
Get more support from