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

Announcements
Qlik Open Lakehouse is Now Generally Available! Discover the key highlights and partner resources here.
cancel
Showing results for 
Search instead for 
Did you mean: 
krishna20
Specialist II
Specialist II

Date Problem

Hi Folks,

I'm trying to do arbitrary date ranges.My database date is not converting to right formatted one. I need to use converted date in the calendar objects. when i'm using this date in the calendar objects,its not working.But, database date is working perfect.Please,anyone suggest me how to achieve this one.  Please find the sample app.

1 Solution

Accepted Solutions
Gysbert_Wassenaar
Partner - Champion III
Partner - Champion III

I've added two variables to change the date format of the values. I've used these two new variables in the Select in Field search string. See attached qvq.

You can also define the default date format for the document in the script using the DateFormat variable. Change it from SET DateFormat='M/D/YYYY'; to SET DateFormat='DD-MM-YYYY';

Note that your date field does not contain dates, but timestamps. You may want to cut off the time part using the floor function: DATE(floor(TP_APPR_DT),'DD-MM-YYYY')as POL_APPR_DATE


talk is cheap, supply exceeds demand

View solution in original post

3 Replies
Gysbert_Wassenaar
Partner - Champion III
Partner - Champion III

I've added two variables to change the date format of the values. I've used these two new variables in the Select in Field search string. See attached qvq.

You can also define the default date format for the document in the script using the DateFormat variable. Change it from SET DateFormat='M/D/YYYY'; to SET DateFormat='DD-MM-YYYY';

Note that your date field does not contain dates, but timestamps. You may want to cut off the time part using the floor function: DATE(floor(TP_APPR_DT),'DD-MM-YYYY')as POL_APPR_DATE


talk is cheap, supply exceeds demand
krishna20
Specialist II
Specialist II
Author

Hi Friends,

Any Idea about this issue !!!

krishna20
Specialist II
Specialist II
Author

Thank you very much Gysbert.