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

If Statement not making sense?

Hi.

I have a problem that I really cant get my head round. its very easy to see if you download the attached qvw. Iunderstand if you dont want to so ill do my best to explain.

there are 2 objects on the right of the Tracker page. 1 is a list box of Period 2 start Dates. there is only one 1/08/13. the 2nd is a pivot table with name and date as dimensions and an expression that states =if(Date <= [Period 2 Start Date],1,2) . for clarity I have forced dates to be numeric in the objects and i can clearly see the point at which Date becomes larger than Period 2 Date start but for some reason the if statement isnt evaulating it as such?

Ive asked this question not long ago but the issue seems a little larger than first described and isnt really applicable to the thread it was in.

Dropbox - boo.qvw

P.s Im only a user so if anyone is able to work out my mistake and explain it to me im would greatly appreciate it.

thanks

3 Replies
Not applicable

Try if(Date={"<=[Period 2 Start Date]"},1,2)

Hope it helps.

Anonymous
Not applicable

Sam,

I can tell that the "Period 2 Start Date" is not associated with the Names, except Alan Hindley and Stephen Brooks - so there is always "2".  If you make selection in "Period 2 Start Date", the expression works as expected.

Regards,

Michael

samuel_brierley
Creator
Creator
Author

Thanks Micheal,

I had loaded Contact Name as Name and that was stopping it from working correctly as they are the contact names but not the only people working on it.

thanks again