Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
I want to make a chart with 2 expressions - Sales and Cost. The way the data is structured, i need different filters on these two to get the right number. For instance, I have two fields "A" and "B" with values "y" and "n" for both. I want "y" to be selected for both A & B to get the right Cost, and don't want any filters on for Sales.
Now if i have a list box and select the "y"s for both A and B, i'd get the right cost but my sales number is off. Is there a way i can work around this? Tried putting an if condition in the expression and calculation condition too but it didn't help.
You can use set analysis expressions:
Cost: sum({<A={'y'},B={'y'}>}CostValue)
Sales: sum(SalesValue)
Replace A, B, CostValue and SalesValue with the names of your fields.
You can use set analysis expressions:
Cost: sum({<A={'y'},B={'y'}>}CostValue)
Sales: sum(SalesValue)
Replace A, B, CostValue and SalesValue with the names of your fields.
Awesome! You're a life saver!
I tried Set but my syntax was off. That'd make sense.
One more question - in a chart, how can i supress/hide some values of a dimension? And i don't want to write the ones selected, but the ones i don't want included (because they are much lesser).
You can use -= to exclude values: {<A -= {'y','z'} >}. The expression editor will mark this as incorrect syntax, but that's a bug in the expression editor.