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: 
Not applicable

Set analysis with a formula

Is there a way to use a formula to the left of the operand in set analysis? Example:

I want:

     Count({$<Month={'1/1/2015'}>}ID)

To read something like:

     Count({$<MonthName(Month)={'1/1/2015'}>}ID)

I've tried numerous ways and I can't seem to figure it out. I know you can do it to the right of the operand, but don't know if it's possible to the left.

This works, as it's on the right of the operand:

     Count({$<Month={"$(=MonthName(vMyDate))"}>}ID)

Thanks in advance

3 Replies
sunny_talwar

You can do this:

=Count({$<Month={"=MonthName(Month) = 'Jan-2015'"}>}ID)


Assuming your Month is actually a date on which you can apply MonthName


HTH


Best,

Sunny

petter
Partner - Champion III
Partner - Champion III

It is not possible to use any kind of expression on the left hand side of the equal sign because this is Set operations ... It compares the Set on the left hand side with the Set on the right hand side. In this case it is a Set of only one element.

The left hand side must contain an explicit field-reference.

petter
Partner - Champion III
Partner - Champion III

Sunindia's suggestion is the way to go to achieve what you are looking for.