Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
Hi All,
I have table like below . My requirement is to filter out the records where shipped =0, I noticed that I can achieve it using the limitation option related to dimension in this case , sector. But the issue is , I have to change the position of 'Shipped' next to Region. The dimension limitation always compare the first measure in the table.
Region | Sales | Orders | Population | Shipped |
A | 10 | 40 | 1000 | 20 |
B | 10 | 40 | 1000 | 22 |
C | 20 | 60 | 4000 | 0 |
D | 100 | 40 | 1000 | 0 |
I have found the solution for this problem, i can use an expression like this.
If(aggr(Measure)),Region)>0,Region), with the dimension and filter out nulls.
Try this,
Only({<Shipped={"<>0"}>}Shipped)
Not sure , I understood your solution, My end result should look like this. And also Shipped is a calculated Measure.
Region | Sales | Orders | Population | Shipped |
A | 10 | 40 | 1000 | 20 |
B | 10 | 40 | 1000 | 22 |
Let me assume the Calculated Expression is A+B
tab1:
LOAD * INLINE [
Region, Sales, Orders, Population, A, B
A, 10, 40, 1000, 10, 10
B, 10, 40, 1000, 10, 12
C, 20, 60, 4000, 0, 0
D, 100, 40, 1000, 0, 0
];
Output:
Note: You can also filter A+B>0 in the Dimension
Thanks for the reply Saran, all the measures are set analysis expressions. Anyway I brought them using variable as shown below. But still not working as expected. and also noticed that Only gives Boolean results.
Only({<Region={"($(A)>0"}>} Sales)
I have found the solution for this problem, i can use an expression like this.
If(aggr(Measure)),Region)>0,Region), with the dimension and filter out nulls.
Great workaround.. I was also struggling for similar to this and you made the day 🙂