Qlik Community

New to QlikView

Discussion board where members can get started with QlikView.

Announcements
Qlik Analytics Tour 2020 Online. Begins August 10th. Register Today
cancel
Showing results for 
Search instead for 
Did you mean: 
Highlighted
Partner
Partner

Set analysis help with variable

Hi all,

I have an expression that i have some set analysis that uses a variable.

The variable is dynamically populated based on a field the user makes selections on.

I need these seletions to be applied to a field in the set analysis.

so basiaclly, the data has a 'Type' field which contains

Bud

Base

Overlay

I then have a data island that has the following

Type_Selection   << field name

Bud,

Base,

Base + Overlay

when i select Bud or Base, this works as it only selects Bud or Base in the Type field.

but when i select Base + Overlay, this relates to 2 of the types, so i need the set analysis to consider both Base and Overlay in the type field.

I have attached a simple sample, could anyone take  a look please?

I know i can link the Type_Selection field to the Type which will work but the problem this causes is it affects the rest of the data and returns incorrect values. So linking would mean that i would have top add in some set analysis to over 100 expressions throughout the QVW to ignore the Type field.

Which is why i am looking to get the set analysis/variable option working instead.

any help would be appreiated

1 Solution

Accepted Solutions
Highlighted
Specialist
Specialist

Re: Set analysis help with variable

Hi, Chris. Maybe this

View solution in original post

2 Replies
Highlighted
Specialist
Specialist

Re: Set analysis help with variable

Hi, Chris. Maybe this

View solution in original post

Highlighted
Master II
Master II

Re: Set analysis help with variable

See if the below helps:

Change your below expression:

Sum({<Type={"($(vBudgetType)))"}>}Value)


     To

IF(GetFieldSelections(TypeSelect)='Base + Overlay',Sum({<Type={'Base','Overlay'}>}Value),Sum({<Type={"($(vBudgetType)))"}>}Value))