Skip to main content
Woohoo! Qlik Community has won “Best in Class Community” in the 2024 Khoros Kudos awards!
Announcements
Nov. 20th, Qlik Insider - Lakehouses: Driving the Future of Data & AI - PICK A SESSION
cancel
Showing results for 
Search instead for 
Did you mean: 
Not applicable

Set Analysis Excluding All Selections

Hi All,

Using Set Analysis can we Exclude all the selections Except one field.

sum({1<FIELD1=FIELD1>} Sales) : This does not work.

Does any one have other alternatives.

Regards,

MAK

1 Solution

Accepted Solutions
rbecher
MVP
MVP

I played around a bit and this works now for me:

sum( {1 < Field3 = {$(=getfieldselections ( Field3 ))} >} Sales )

Just without the quotes! 😉

Astrato.io Head of R&D

View solution in original post

17 Replies
Not applicable
Author

sum( {1<FIELD={Value} Sales>} This works but it is restricted to this Value. I want it to be depended on only one field selection.

Can any body do this?

yblake
Partner - Creator II
Partner - Creator II

to get all selection except set A, use {1-A}

rbecher
MVP
MVP

I'm not sure if I understand what you want, but

sum( {1-$} Sales )

will summarize all except the selections.

Astrato.io Head of R&D
Not applicable
Author

As you said , {1-$} will give All except the selections.

Here is what I want exactly

If I make selections on Field1 , Field2 , Field3....., Field100.

I want to summarize by Ignoring all selections but Including Field3 Selection.

rbecher
MVP
MVP

This will summarize all Sales values with the current Field3 selection:

sum( {1 < Field3 = {"$(=getfieldselections ( Field3 ))"} >} Sales )

Will work only if a single value is selected.

Astrato.io Head of R&D
Not applicable
Author

Thanks Ralf.

Is there any solution for Multiple Values?

rbecher
MVP
MVP

I played around a bit and this works now for me:

sum( {1 < Field3 = {$(=getfieldselections ( Field3 ))} >} Sales )

Just without the quotes! 😉

Astrato.io Head of R&D
Not applicable
Author

Thanks Ralf,
I tried removing Quotes. It doesnt work.

Did you change anything else?

rbecher
MVP
MVP

No. It depends on the values of Field3. Do you have values with blanks or strange chars?

This is my last idea:

sum( {1 < Field3 = {$(=getfieldselections ( Field3, ',', 100 ))} >} Sales ) // getfieldselections with comma separator, max 100 values (default is 6)

You can check the return of getfieldselections ( Field3, ',', 100 ) if you insert it as a formula. It should return a comma separated value list.

Astrato.io Head of R&D