Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
Hello,
I have an value in my application, [ExtNetDollars], and I have an Input Box which exposes two varaibles; vMinNetSales and vMaxNetSales. I have a straight table which is showing [ExtNetDollars], and I want to set it up to filter any rows where [ExtNetDollars] is not within the range defined by these two variables. I tried to start by just limiting to rows where [ExtNetDollars] was greater than the min, by trying the below, but it didn't work;
sum({<ExtNetDollars > $(vMinNetSales)>}ExtNetDollars)
Any help would be appreciated.
Thanks!
Chris
What you needed to do was to compare after you have done the sum already, you can use this if statement as expression:
if(sum(ExtNetDollars)>vMinNetSales and sum(ExtNetDollars)<vMaxNetSales, sum(ExtNetDollars))
or if you don't like using if statements, calculate the sum in the script first.
Hope this helps!
Try something like this:
sum({<ExtNetDollars = {'>$(vMinNetSales)<$(vMaxNetSales)'}>}ExtNetDollars)
Hope this helps!
Thanks!
This worked, but perhaps I didn't know what I really wanted to achieve. Here is an example of what my straight table looks like with a simple expression to show ExtNetDollars, no variables and no set analysis.
I then have the following values set for my two variables;
What I then see is the following;
What I expected to happen was each district below or above $51,000,000 would dissappear, but it appears what QV is doing is evaluating the net sales at a lower level. How could I get the desired result?
Thanks!
Chris
What you needed to do was to compare after you have done the sum already, you can use this if statement as expression:
if(sum(ExtNetDollars)>vMinNetSales and sum(ExtNetDollars)<vMaxNetSales, sum(ExtNetDollars))
or if you don't like using if statements, calculate the sum in the script first.
Hope this helps!
Perfect!
Thank you very much.
Chris