Qlik Community

QlikView Deployment

Discussion Board for collaboration related to QlikView Deployment.

agigliotti
Honored Contributor II

Getting data from DB2/AS400 in wrong data type

Hi,

I faced this issue for the second time in reading data from DB2 on AS400.

Specifically some of fields declared as CHAR on DB2 I get those fields as numeric/integer rather than text/ascii (Tags) on QlikView and it causes wrong data result.

I noted the values on those fields are numeric and alphanumeric (ex. 3, 03, abcd, etc...).

Is this a problem of ODBC driver I'm using ? Is there some settings I have to looking for ?

Currently I'm using iSeries Access ODBC Driver version 13.64.08.00

Can someone drives me to the right direction to fix this problem ?

Many thanks in advance.

Best Regards

Andrea

Tags (1)
3 Replies
Employee
Employee

Re: Getting data from DB2/AS400 in wrong data type

It is probably QlikView's automatic number interpretation that kicks in. See http://community.qlik.com/blogs/qlikviewdesignblog/2013/07/07/automatic-number-interpretation.

To avoid it, you could load the field as

     Text(Field) as Field

HIC

agigliotti
Honored Contributor II

Re: Getting data from DB2/AS400 in wrong data type

Hi Henric,

Thank you for your help, however I already used your workaround but I thought that was another reason for this issue (ex. odbc driver).

Do you think it's better to apply the Text function for each field declared as CHAR on DB2 ?

Regards

AG

Employee
Employee

Re: Getting data from DB2/AS400 in wrong data type

It is only necessary in the cases where you have something that looks like numbers of dates - but aren't.

In my experience, it is not uncommon that some fields are declared CHAR, but really contain a number or a date. In these cases you want to have the number interpretation working, so to use it everywhere seems like overkill to me.

HIC

Community Browser