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: 
jananireddy1
Contributor III
Contributor III

Search condition for date in a timestamp field

Hi Fellow Qlikers, 

I am trying to search a column of a table. The field coming from db is a timestamp field. 

jananireddy1_0-1615577188481.png

 Is there a way i can ignore the timestamp and just be able to write my search condition as  >=02/20/2020 and it still fetches me results 

jananireddy1_1-1615577274969.png

 

 

JR
Labels (3)
13 Replies
eddie_wagt
Partner - Creator III
Partner - Creator III

Hello @jananireddy1 ,

Could you check if this expression is better? I cannot test it myself.

=dual(created_date,num(Timestamp(created_date)))

Regards

Eddie

jananireddy1
Contributor III
Contributor III
Author

Perfect! I think this works, i am testing out a few more use cases with this. Meanwhile i am hoping you could explain this to me in a few words? Wondering why the timestamp format does not work as it is 

JR
eddie_wagt
Partner - Creator III
Partner - Creator III

Great. Hopefully it works for you. I am guessing here, but I think the timestamp is not being interpreted as a integer/number. With the expression dual you can combine a string (what you want to see) with a number (what has to be caculated).

Maybe if you try to solve it in loadscript, you can load the timestamp like this.

 Time( TimeField, 'hh:mm:ss TT')

Maybe this is a solution? Again I cannot see the source so maybe the formula has to be tweakerd.

Regards Eddie

jananireddy1
Contributor III
Contributor III
Author

Sounds good! i can try playing around in the load script as well. But for now your solution works perfectly good. 

 

Thankyou

JR