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

Use 'and' and 'or' in SET analysis on the same dimension

HI there. Can anyone help a newbie a little?

I want to sum all "Answer" (1 or 0)  that has answered either '2_q10N1_1' or   '2_q10N1_2'  AND that has answered '2_q9b10N3_4' or '2_q9b10N3_5' for Answer_ID.

=sum({<Answer_ID={'2_q10N1_1','2_q10N1_2'} * {'2_q9b10N3_4','2_q9b10N3_5'} >}Answer)

Is there a way to do this?

Thank you

1 Solution

Accepted Solutions
Gysbert_Wassenaar
Partner - Champion III
Partner - Champion III

Maybe like this:

=sum({<Answer_ID={'2_q10N1_1','2_q10N1_2'}, Respondent_ID=P({<Answer_ID={'2_q9b10N3_4','2_q9b10N3_5'} >}Respondent_ID)>}Answer)


talk is cheap, supply exceeds demand

View solution in original post

2 Replies
Gysbert_Wassenaar
Partner - Champion III
Partner - Champion III

Maybe like this:

=sum({<Answer_ID={'2_q10N1_1','2_q10N1_2'}, Respondent_ID=P({<Answer_ID={'2_q9b10N3_4','2_q9b10N3_5'} >}Respondent_ID)>}Answer)


talk is cheap, supply exceeds demand
Not applicable
Author

Thank you Gysbert