Skip to main content
Announcements
Qlik Connect 2024! Seize endless possibilities! LEARN MORE
cancel
Showing results for 
Search instead for 
Did you mean: 
Anonymous
Not applicable

Set Analysis

Hi,

I want to use a part of set analysis to be stored in variable. Any suggestions?

I have data like,

Description   Amt

A                   100

B                   200

C                   300

D                    400

Set analysis is like =sum({<Description = {'A'}> }Amt). But I want to store Description = {'A'} in a variable and use that in a expression.


6 Replies
Digvijay_Singh

May be like this -

Capture.PNG

Capture1.PNG

Anonymous
Not applicable
Author

Thanks its working.

May I know why we get red line?

Digvijay_Singh

You may ignore that, its showing because editor assumes set expression is not properly written.

vishalarote
Partner - Creator II
Partner - Creator II

May be Try this Manner

make Variable vDescA

Description='A'

n write Set Analysis like

sum({<Description={"=$(vDescA)"}>}Amt)

Capture9.PNGCapture7.PNG

Anonymous
Not applicable
Author

if I want to add A Or B or C, then expression isn't working

vishalarote
Partner - Creator II
Partner - Creator II

then u used in vDesc

wildmatch(Description,'A','B','C')

and Write expression in text object

sum({<Description={"=$(vDesc)"}>}Amt)