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

Announcements
Want to see what's currently in public preview? We've pulled it all together in one place. Check it out here
cancel
Showing results for 
Search instead for 
Did you mean: 
Not applicable

Storing Multiple Values in a Variable for Set Analysis

Hi,

I have a couple of buttons that has an action to set a variable, vQuarter, to either Q1, Q2, Q3, or Q4 that works perfect. However, I want a button that can set the quarter to a combination of Q1 and Q2. Is this possible?

Default in load script:

LET vQuarter='*'

In my expression I am using:

sum($*{<[Quarter]={"$(=vQuarter)"}>} [Responses])

I tried putting various methods with no success:

("Q1"|"Q2")

Q1,Q2

etc..

Thanks in advance!

-Jason

Labels (1)
1 Solution

Accepted Solutions
robert_mika
MVP
MVP

sum({<[Quarter]={$(vQuarter)}>} [Responses])


variable

vQuarter:

Q1,Q2

View solution in original post

2 Replies
robert_mika
MVP
MVP

sum({<[Quarter]={$(vQuarter)}>} [Responses])


variable

vQuarter:

Q1,Q2

Not applicable
Author

Thanks Robert! Worked beautifully!

-Jason