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

Announcements
Join us in Toronto Sept 9th for Qlik's AI Reality Tour! Register Now
cancel
Showing results for 
Search instead for 
Did you mean: 
ipauldur
Creator
Creator

Date format for DB2 database

Hi,

Is there any specific date format required while extracting data from DB2 database?

Because, I have extracted data from the DB2 database.In that data, date values are showing in numbers.

If we are using, mid,left or right function then i am not able to get proper date format for all values.

Is there any specific date format for DB2 db.

Thanks in advance,

Regards,

Durai

11 Replies
Not applicable

Here is another solution in converting a db2 date as part of the data load.

SUBSTR(DIGITS(DATEFIELD), 5, 2)||'/' || SUBSTR(DIGITS(DATEFIELD), 7, 2)||'/'||SUBSTR(DIGITS(DATEFIELD), 1, 4) AS dateName

priyav24
Creator II
Creator II

Try this

=Date(AddYears(Date(Date#('19'&Right(DateField,6),'YYYYMMDD'),'DD/MM/YYYY')

          ,100*Left(DateField,1)),'DD/MM/YYYY')