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

Announcements
FLASH SALE: Save $500! Use code FLASH2026 at checkout until Feb 14th at 11:59PM ET. Register Now!
cancel
Showing results for 
Search instead for 
Did you mean: 
sandeepprasad_j
Creator
Creator

Help In Set Analysis Expression?

Hello Experts,

Can you please help me in writing the set analysis expression for the below if condition

If(vPer=12,sum([Amt]),(if(vPer=6, sum([Amt]))))

Thanks in advance

Cheers

Sandeep

Labels (1)
12 Replies
tresB
Champion III
Champion III

Here set analysis would not be required. Don't worry about using it. Carry on with your expression.

sandeepprasad_j
Creator
Creator
Author

Thanks everyone for your help

Cheers

smaqsood_cv
Partner - Contributor
Partner - Contributor

Hi,

You can use something like this

Sum(Pick(match(vPer,{vListOfFieldName}),{vListOfActualField}))

where

vListOfFieldName is a variable which is a concatenated list (& comma separated) of part of the field names that matches your vPer values

vListOfActualField is another variable which is a concatenated list of actual fields

E.g: if vPer values are 6, 12

then, vListOfFieldName = 6, 12

vListOfActualField = [6 Amt], [12 Amt]