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

find date is greater than or not without set analysis

if(paymentDate >= date($(SelectDateFrom),'MM-DD-YYYY'), True, False)

PaymentDate=15-06-2017

SelctedDateFrom=01-06-2017

But output is showing false please suggest the correct syntax to get the exact output

11 Replies
Sergey_Shuklin
Specialist
Specialist

Hello!

Is this format "MM-DD-YYYY" suitable for such values 15-06-2017?

avkeep01
Partner - Specialist
Partner - Specialist

Hi manoj217‌,

Try '$(SelectedDateFrom)' and SelectedDateFrom instead of $(SelectedDateFrom) of maybe even $(=SelectedDateFrom). That can give different results.

Maybe it is because PaymentDate is with or without the capital P. But that is just a guess based on the different ways you wrote paymentDate.

avkeep01
Partner - Specialist
Partner - Specialist

Also you use: SelectDateFrom and SelctedDateFrom in your post. Maybe that is also wrong in you application.

sunny_talwar

Try this

If(paymentDate >= Date#($(SelectDateFrom), 'MM-DD-YYYY'), True, False)

sunny_talwar

or this

If(paymentDate >= Date#('$(SelectDateFrom)', 'MM-DD-YYYY'), True, False)

avkeep01
Partner - Specialist
Partner - Specialist

Try this, in my case it worked. 

=if(PaymentDate>= date('$(SelectedDateFrom)'), True(), False())

andrei_delta
Partner - Creator III
Partner - Creator III

hi,

you should format the "SelectDateFrom" as 'DD-MM-YYYY'.

manoj217
Creator III
Creator III
Author

Sorry i gave an example only.

consider

paymentdate =06-15-2017

selecteddatefrom=06-01-2017

manoj217
Creator III
Creator III
Author

not working every time it is showing false only