Do not input private or sensitive data. View Qlik Privacy & Cookie Policy.
Skip to main content

Announcements
Join us to spark ideas for how to put the latest capabilities into action. Register here!
cancel
Showing results for 
Search instead for 
Did you mean: 
JuMo
Creator
Creator

How to make a COunt If, when month is smaller tha a given month

Hello

I want to make a count If for flags, If flag has been received before a given month

The following one is OK, but that's not what I want
Count({<[Global Date]=10>}[FLAG])

This one is not working
Count({<[Global Date]<=10>}[FLAG])

Neither this one
Count({<Month([Global Date])=10>}[FLAG])

And of course nor this one
Count({<Month([Global Date])<=10>}[FLAG])

What shall I do ?

Labels (1)
1 Solution

Accepted Solutions
Chanty4u
MVP
MVP

try this

script:

LOAD

     Month(Date) as Month,

     Num(Month(Date)) as MonthNum,

     

 

in front end

count{$<MonthNum ={"<=$(=Num(Month(Today())))"}>} Flag)

View solution in original post

2 Replies
Chanty4u
MVP
MVP

try this

script:

LOAD

     Month(Date) as Month,

     Num(Month(Date)) as MonthNum,

     

 

in front end

count{$<MonthNum ={"<=$(=Num(Month(Today())))"}>} Flag)

JuMo
Creator
Creator
Author

Thank you, it workds, however, I don't undertand why the characters in green here:

count{$<MonthNum ={"<=$(=Num(Month(Today())))"}>} Flag)