Page 1 of 1

Comparison logic not working

Posted: Thu Nov 30, 2017 4:34 am
by esivaprasad
Hi Team ,


In our project , we are doing reconcillation on 2 sources.
in both source , one source file is in .txt format and other source is in form of .csv .

In reconcillation job before comparing 2 sources , in transformer stage , we are trimming all fields in both source files.
for reconcillation , we are using CDC stage.
after cdc stage , we have target stage .
few records are coming as not matching records, if we see those records, that are same in both sources.


we have seen those records in notepad, textpad and in excel , but records are same , still it coming as not matching one to other source record values.
Please let me know other trim and tril leading trailing functions , what functions we can use for triming.

Source|SourceSystem|Customer_Number|Account_Group|Name1|Fax_Country|Fax_Number|Sequence_Number|Standard_Fax_No
Source1|LA|0000013010|Z012|INDUSTRIA DE LICORES DEL VALLE|CO|2 68303||
Source2|LA|0000013010|Z012|INDUSTRIA DE LICORES DEL VALLE|CO|2 68303||

Posted: Thu Nov 30, 2017 8:05 am
by qt_ky
Perhaps one record contains non-printable control characters or the ASCII NULL character 0x00 which is often introduced by DataStage due to the default setting of the project environment variable APT_STRING_PADCHAR. We always override the default setting at the project level by using 0x20 instead, which is a space. If you view your text file records in hex, maybe something will jump out.

Posted: Thu Nov 30, 2017 8:07 am
by chulett
Was just going to suggest much the same thing - get thee to a hex editor! Or an octal dump "od" can be leveraged on the server.

Posted: Thu Nov 30, 2017 11:18 am
by Mike
If by CDC you mean the Change Capture stage, then be aware that it requires unique keys on both input links. You can see the result you describe when there are duplicate keys.

Mike