Skip to main content
Announcements
Qlik Connect 2024! Seize endless possibilities! LEARN MORE
cancel
Showing results for 
Search instead for 
Did you mean: 
aniruddhyadutta
Creator
Creator

date comparision is not happeing for delta load

Hi Friends,

I am doing an incremental load from orace db through qliksense script.But the the compariosn in where caluse is not happening which I guess qlik is not able to pass the varibale value to oracle.

If I hard code in the where clause then it works

where LAST_DATE_TIME > TO_DATE('12/20/2016  2:29:57 AM','MM/DD/YYYY HH:MI:SS PM');

But If I am using the variable its not working though the variable is returning value

where LAST_DATE_TIME > TO_DATE('$(last_Updated_Date)','MM/DD/YYYY HH:MI:SS PM');

in qlik I am getting the last_Updated_Date as a format like this

Capture.PNG

Thanks much

AD

12 Replies
aniruddhyadutta
Creator
Creator
Author

Thanks Sunny for your reply.

As of now I ddint tried your way since the way gysbert suggest did workd which I tried first  . since it was urgent it didn't tried more.But I will let you know if also your way do work or not..:)

sunny_talwar

I think what you have found is true. It doesn't matter if you use AM, PM or A.M. or P.M. as long as you use one of them.

https://www.techonthenet.com/oracle/functions/to_date.php

Capture.PNG

Gysbert_Wassenaar

Like Sunny says, the format string for oracle's to_date function can be constructed in several ways to indicate an AM/PM kind of timestamp. There's no difference between AM and PM because you're not specifying a timestamp value, but a timestamp format. As soon as you use AM or PM then it's clear that you're specifying an AM/PM input format and not a HH24 format.


talk is cheap, supply exceeds demand