Skip to main content
Announcements
Have questions about Qlik Connect? Join us live on April 10th, at 11 AM ET: SIGN UP NOW
cancel
Showing results for 
Search instead for 
Did you mean: 
nisha_rai
Creator II
Creator II

Filter base Selection

Hi,

I have to show sum of sales for particular location,but if we select other location it should show Zero.

For example:

Country Sales

India 200

US 300

UK 100

Result : when no filter select from Country

India = 200 US = 300 UK =100  /// I am using set analysis for that

If we select India from Country List box

India = 200 US =0 UK =0 // Set analysis is not working it show India=200 US =300 UK =100

Please suggest me how to solve that to retrive the result.

Regards,

Nisha

1 Solution

Accepted Solutions
tresesco
MVP
MVP

May be like:

Capture.PNG

Capture2.PNG

Use Implicit set expression like:  Sum({<Country*={'India'}>}Sales)

View solution in original post

19 Replies
trdandamudi
Master II
Master II

May be as below:

=If (GetSelectedCount(Country)>0, Sum (Sales),0)

nisha_rai
Creator II
Creator II
Author

if the user select India and US then it should be Inid=200 US=300 UK=0 like that

Anonymous
Not applicable

Hi Nisha,

Apply GetCurrentSelections() in your expression.

Thanks,

Pooja

nisha_rai
Creator II
Creator II
Author

And all those value we have to display in a text box not in a list box

nisha_rai
Creator II
Creator II
Author

Hi Pooja,

I tried if(Getselectedcount(Country)=0 or if(match(Getcurrentselections(Country),'Inida'),1),1,0)

but it's doesn't give me result when i m selecting two country at a time

trdandamudi
Master II
Master II

Please see the attached and hope this is what you want:

nisha_rai
Creator II
Creator II
Author

i am not able to see your attachment

trdandamudi
Master II
Master II

If you are in the Inbox than you will not see it. just go to the webpage and you will see it..

nisha_rai
Creator II
Creator II
Author

In a chart or in list bix it's working fine, but i need to show all those information in text box

Example:

India(text box)

200(Sum({<Country={'India'}>}Sales)) show in a text box

it's work fine if we are not selecting any thing but when i am selecting Country as UK it still show 200 in that text box