Focal Point
[CASE-OPENED] DB2 bulkload converts empty strings into null value

This topic can be found at:

July 10, 2013, 05:56 AM
Martin vK
[CASE-OPENED] DB2 bulkload converts empty strings into null value
In DB2 (and other SQL databases I know) there is a clear difference between a CHAR field with empty string '' value and null (missing) value.
When using DB2 bulkload however data from the source is first put in a tab-delimited file on the DM server which uses unquoted strings, so there is no difference between the 2 values anymore.
This means an empty string in the source data is being loaded as a null value in the target, which is not the same as the source value.
Unfortunately I also have VARCHAR fields in the DB2 target table defined with NOT NULL, so I get errors on those records and they are rejected in the load, while the empty string should be accepted.

The problem seems to be that the intermediate tab-delimited file uses unqouted strings, if it uses quoted strings it would not cause this problem.

Is there some setting that DM will use quoted strings in the intermediate tab-delimited file for the bulkload?

This message has been edited. Last edited by: <Kathryn Henning>,

WebFocus 8206M, iWay DataMigrator, Windows, DB2 Windows V10.5, MS SQL Server, Azure SQL, Hyperstage, ReportCaster
July 15, 2013, 12:32 PM
<Kathryn Henning>
Hi Martin,

This looks like it's going to require some research, so I'd like to recommend opening a case on InfoResponse Online.