Do not input private or sensitive data. View Qlik Privacy & Cookie Policy.
Skip to main content

Announcements
Join us in NYC Sept 4th for Qlik's AI Reality Tour! Register Now
cancel
Showing results for 
Search instead for 
Did you mean: 
paolo_cordini
Partner - Creator
Partner - Creator

Inconsistent trailing zeros behavior

Hi 

I have the following script (simplified)

LOAD
    Trim(Text(EAAITM)) AS TrimText_EAAITM,
    Text(EAAITM)       AS Text_EAAITM,
    EAAITM             AS EAAITM,
 ;
SQL SELECT
    EAAITM
FROM S78EE370.M3FDBPRD.FCHACC
WHERE EACONO IN ('10', '20')
WITH UR;
 
And this is a sample of the result. The trailing '0' are kept or removed in different way but I cannot find a rule.
I guess the original field has some difference in the output of the database driver (DB2 in this case)
paolo_cordini_0-1727338939102.png

 

Any ideas?

Regards
Paolo

Labels (1)
1 Solution

Accepted Solutions
marcus_sommer

As troubleshooting respectively as parts of a solution or a workaround you may try to cast this field within the sql to a certain/common type of string or to combine the field in a way like:

chr(1) & '|' & MyField as MyField

to get a definite output for the Qlik-side in which these extras are removed + converted/formatted as wanted.

View solution in original post

3 Replies
marcus_sommer

As troubleshooting respectively as parts of a solution or a workaround you may try to cast this field within the sql to a certain/common type of string or to combine the field in a way like:

chr(1) & '|' & MyField as MyField

to get a definite output for the Qlik-side in which these extras are removed + converted/formatted as wanted.

paolo_cordini
Partner - Creator
Partner - Creator
Author

Yes, this is what I did and it works. But it is weird anyway.

 

marcus_sommer

This means the Qlik-side worked as expected and the inconsistence comes from the data-base and/or the driver respectively their combination. Maybe the driver is not suitable (wrong one or not the right release) and/or any configuration isn't set properly. Maybe the FAQ and/or the community from the data-base/driver could deliver any hints.