Qlik Community

QlikView Scripting

Discussion Board for collaboration on QlikView Scripting.

Not applicable

automatically convert Numeric Field

buonasera, Vorrei sapere come posso evitare che un istruzione SQL SELCT converta in automatico un campo alfanumerico esemoio 01, 001, 1, in unuco valore numerico  1 o 01 o 001....

non  posso usare un load prima del sql, cerco un settaggio

grazie

..

Good evening, I would like to know how can I prevent a SQL statement SELCT automatically convert an alphanumeric field esemoio 01, 001, 1, UNUCI numerical value 1 or 01 or 001 ....
I can not use a load before the sql, I look for a setting

thanks

Tags (1)
1 Solution

Accepted Solutions
MVP
MVP

Re: automatically convert Numeric Field

Hi Massimo,

Use the Text() function to keep those leading and trailing zeroes

Table:

LOAD Text(Code) AS Code;

SQL SELECT Code

FROM Table;

The LOAD part is executed in QlikView and their functions have nothing to do with SQL, so if the driver returns the right data, the above will work.

Hope that helps.

Miguel

1 Reply
MVP
MVP

Re: automatically convert Numeric Field

Hi Massimo,

Use the Text() function to keep those leading and trailing zeroes

Table:

LOAD Text(Code) AS Code;

SQL SELECT Code

FROM Table;

The LOAD part is executed in QlikView and their functions have nothing to do with SQL, so if the driver returns the right data, the above will work.

Hope that helps.

Miguel

Community Browser