Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
I'm loading some data from a sql server database
CODE 001, description (TXT) Acquisto su ....
CODE 01, description (TXT) Vendita normale
Same data loaded with same query in qlikview (image below)
DLVREASON:
LOAD * ;
SQL
select CODE, TXT
from dlvreason where code < '20'
and dataareaid='els6' order by 1;
and I have the same 001 CODE with two different description
Code 001, description (TXT) Acquisto su ....
Code 001, description Vendita normale
has anyone encountered the same problem? solution?
Try to load it as text:
LOAD
text(CODE) as CODE,
TXT;
SQL SELECT
CODE,
TXT
FROM ...
Try to load it as text:
LOAD
text(CODE) as CODE,
TXT;
SQL SELECT
CODE,
TXT
FROM ...
Qlikview interprets your codes as numbers with a display format. The first 001 is interpreted as 1 with display format 001. The next value 01 is also interpreted as 1 and gets the same display format as the first 1 because a number can have only one display format. And so on for 002-02, 003-03 etc. The solution is to use the text() function:
DLVREASON:
LOAD text(CODE),TXT ;
SQL
select CODE, TXT
from dlvreason where code < '20'
and dataareaid='els6' order by 1;