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: 
mahitham
Creator II
Creator II

Flag help

Hi Experts,

Can any one please help me to create the below flag.

When Date 1 is greater than or equal to Date 2 then it  has to show 1 else 0. But when Date 1 and Date 2 both are same getting 0 instead of 1. Please help me on this.

Please find the below attached app.

Thanks in advance.

Date.png

1 Solution

Accepted Solutions
basildur
Contributor III
Contributor III

@mahitham Hi, try this 

=if(num(floor(Date1))>=num(floor(Date2)),1,0)

 

It's probably because of your date format, if you convert in into a floored numeric value it should work.

 

Best Regards,

Vlad

View solution in original post

3 Replies
basildur
Contributor III
Contributor III

@mahitham Hi, try this 

=if(num(floor(Date1))>=num(floor(Date2)),1,0)

 

It's probably because of your date format, if you convert in into a floored numeric value it should work.

 

Best Regards,

Vlad

Mauritz_SA
Partner - Specialist
Partner - Specialist

Hi Mahitham

Vlad is correct. Your date part of the two dates are the same, but your timestamp of Date2 is bigger. I checked and if(Floor(Date1)>=Floor(Date2),1,0) also works without converting to a number.

Regards,

Mauritz

mdmukramali
Specialist III
Specialist III

Hi,

 

can you try something like 

 

=if(floor(Date1)>=floor(Date2),1,0)

Date.PNG