Qlik Community

Ask a Question

QlikView App Dev

Discussion Board for collaboration related to QlikView App Development.

Announcements
On Demand Webinar: See Why Thousands of QlikView Users Have Switched to Qlik Sense. REGISTER
cancel
Showing results for 
Search instead for 
Did you mean: 
southwinds
Contributor
Contributor

Using an Expression stored in a variable in set analysis

I have defined a variables vExp in variable overview as following:

Concat(distinct 'IF(GetSelectedCount(['&[$Field]&']) > 0, '& chr(39) & '<[' & chr(39) &' & concat(distinct {<[$Field] = {"*"} - {' & chr(39) & [$Field] & chr(39) &'}>} [$Field], ' & chr(39) &']=,[' & chr(39) &') & ' & chr(39) & '] = > + ' & chr(39) &')')

I have borrowed this from internet, and I want to do an OR mode between more than two list boxes.

Refer to this link: http://www.qlikfix.com/2013/10/23/and-or-mode-selections-in-qlikview/

I think the expression is correct. Now, I wish to use it in a chart like =Sum({$(vExp)} Quantity). But for some reason I haven't been able to get this to work. Can anyone help me on this?

I am new to Qlikview and don't have much understanding around how variables work.


 

5 Replies
tresesco
MVP
MVP

Could you share your sample app where this can be tested? Also please describe your expected output with logical explanation.

southwinds
Contributor
Contributor

Here, I have the list boxes from which i wish to select data. I have got a chart where i want the selections to reflect. Thanks.

southwinds
Contributor
Contributor

What I want is that if you make some selections in one of the list boxes, and then make some more in others, all of them should reflect in the chart like an 'or' condition, instead of how they become 'and' selections in qlikview by default. So, I wish to see something like if my Customer is somebody, or if the product is something then give me all of them. I hope it is clear now.
tresesco
MVP
MVP

I presume (since, I can't download Barry's sample app right now) that there is some gap between your approach and what Barry has suggested in his post. I would request you to download his sample app and go through it thoroughly before you attempt to implement in your app. It is imperative to understand what $Field is and how the concat() storing the selected values from fields in variables.
Deboshmita
Contributor
Contributor

That is the gap in Barry's post ... A lot of people have been trying to get that solution to work. ..If anyone's been able to implement it completely and obtain 'OR' selections... please share here