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: 
acbishop2
Creator
Creator

Set Analysis Ignoring Selection

Hi All,

I have an expression in set notation that I need to be affected by the filter I choose. From what I understand, the {$<>} notation is supposed to be affected by the filters/selections, yet it isn't changing in this case. My expression is:

Sum({$<[Team] = {"Original"},Month = {"$(=Month($(vMaxDate)))"}>}[Lead Goal])

In other words, the value displayed should be the current month's Lead Goal for the Original Team. It gives me the correct value, but when I use my [Team] filter, it stays the same. If I select a [Team] other than "Original", I want the value to be 0.

Thank you in advance for shedding some light on this.

Aaron

1 Solution

Accepted Solutions
Digvijay_Singh

What I understand is, the modifier {Team]={'Original'} overrides the selections in the Team field. So whatever you choose, this particular chart would not be affected by the selections in Team field. the {$<>} allows to make selections in other fields and they will impact the result.

I think you need something like this, need to test the syntax -

Sum({$(<[Team] = {'Original'}>*<Team=P(Team)>)*<Month = {"$(=Month($(vMaxDate)))"}>}[Lead Goal])

View solution in original post

4 Replies
Digvijay_Singh

What I understand is, the modifier {Team]={'Original'} overrides the selections in the Team field. So whatever you choose, this particular chart would not be affected by the selections in Team field. the {$<>} allows to make selections in other fields and they will impact the result.

I think you need something like this, need to test the syntax -

Sum({$(<[Team] = {'Original'}>*<Team=P(Team)>)*<Month = {"$(=Month($(vMaxDate)))"}>}[Lead Goal])

acbishop2
Creator
Creator
Author

You did it again, Digvijay!

Here's the solution with final syntax:

SUM({$<[Team] = {'Original'}>*<[Team]=P([Team])>*<Month = {"$(=Month($(vMaxDate)))"}>}[Lead Goal])

I hadn't ever seen the P() function. Thanks for introducing it to me!

sunny_talwar

This might have worked also

SUM({$<[Team] = {'Original'}*P([Team]), Month = {"$(=Month($(vMaxDate)))"}>}[Lead Goal])

sunny_talwar

Actually this should work even better

SUM({$<[Team] *= {'Original'}, Month = {"$(=Month($(vMaxDate)))"}>}[Lead Goal])