Microsoft is giving away 50,000 FREE Microsoft Certification exam vouchers!
Enter the sweepstakes now!Prepping for a Fabric certification exam? Join us for a live prep session with exam experts to learn how to pass the exam. Register now.
Hi,
I have the following measure:
Can you filter avoid the blank rows? It Agg is coming zero
in case of row is zero and you want to avoid
MEDIANX( filter('All Store Info',condition to filter),
Appreciate your Kudos. In case, this is the solution you are looking for, mark it as the Solution. In case it does not help, please provide additional information and mark me with @
Thanks.
Hi @duggy ,
I think you should create a calculated column not a measre in your scenario. Here we can update the formula as below.
MEDIANFilter = IF ( 'All Store Info'[Turnover] = BLANK (), BLANK (), MEDIANX ( FILTER ( 'All Store Info', 'All Store Info'[Turnover] <> BLANK () ), DIVIDE ( 'All Store Info'[Turnover], 'All Store Info'[Transactions] ) ) )
That would be ideal however the reason I used the measure is that I need to get the value of the slider.
Basically the user can slide the slider and select the amount to add:
I had a similar problem in a What-if scenario, but worked around it by using a variable and wrapping the result in an IF that would return FALSE if blank/0 which forces the MEDIANX to ignore the result.
MEDIANX (
'All Store Info',
VAR _Result =
DIVIDE ( 'All Store Info'[Turnover], 'All Store Info'[Transactions] ) + 'Increase of Basket Value'[Increase of Basket Value Value]
RETURN
IF ( _Result <> 0, _Result, FALSE () )
)
User | Count |
---|---|
85 | |
73 | |
73 | |
57 | |
51 |
User | Count |
---|---|
44 | |
41 | |
34 | |
34 | |
30 |