Register now to learn Fabric in free live sessions led by the best Microsoft experts. From Apr 16 to May 9, in English and Spanish.
Hi All
Solved! Go to Solution.
Hi @admin11 ,
It would be like this:-
_amount_select3 =
VAR VAR1 =
SUM ( 'SALES'[sales] )
RETURN
SWITCH (
SELECTEDVALUE ( SliceTable[Slice] ),
"BRAND_C",
IF (
ISINSCOPE ( summrizetable2[rank] ),
CALCULATE ( VAR1 ),
FILTER (
ALLSELECTED ( 'SALES' ),
[BRAND_C] = MAX ( 'summrizeTable1'[BRAND_C] )
)
),
VAR1
)
Thanks,
Samarth
Best Regards,
Samarth
If this post helps, please consider accepting it as the solution to help the other members find it more quickly.
Appreciate your Kudos!!
Connect on Linkedin
Hi @admin11 ,
It would be like this:-
_amount_select3 =
VAR VAR1 =
SUM ( 'SALES'[sales] )
RETURN
SWITCH (
SELECTEDVALUE ( SliceTable[Slice] ),
"BRAND_C",
IF (
ISINSCOPE ( summrizetable2[rank] ),
CALCULATE ( VAR1 ),
FILTER (
ALLSELECTED ( 'SALES' ),
[BRAND_C] = MAX ( 'summrizeTable1'[BRAND_C] )
)
),
VAR1
)
Thanks,
Samarth
Best Regards,
Samarth
If this post helps, please consider accepting it as the solution to help the other members find it more quickly.
Appreciate your Kudos!!
Connect on Linkedin
@admin11 ,Please try this:-
_amount_select3 =
SWITCH (
SELECTEDVALUE ( SliceTable[Slice] ),
"BRAND_C",
IF (
ISINSCOPE ( summrizetable2[rank] ),
CALCULATE (
VAR1,
FILTER (
ALLSELECTED ( 'SALES' ),
[BRAND_C] = MAX ( 'summrizeTable1'[BRAND_C] )
)
),
VAR1
)
)
Best Regards,
Samarth
If this post helps, please consider accepting it as the solution to help the other members find it more quickly.
Appreciate your Kudos!!
Connect on Linkedin
i Just notice that all row return same value.
Hope you can advise me where go wrong ?
Paul
Small correction. Please try this:-
_amount_select3 =
VAR VAR1 =
SUM ( 'SALES'[sales] )
RETURN
SWITCH (
SELECTEDVALUE ( SliceTable[Slice] ),
"BRAND_C",
IF (
ISINSCOPE ( summrizetable2[rank] ),
CALCULATE (
VAR1,
FILTER (
ALLSELECTED ( 'SALES' ),
[BRAND_C] = MAX ( 'summrizeTable1'[BRAND_C] )
)
)
),
VAR1
)
Best Regards,
Samarth
If this post helps, please consider accepting it as the solution to help the other members find it more quickly.
Appreciate your Kudos!!
Connect on Linkedin
@admin11 is it possible for you to share your PBIX file after removing sensitive data since its bit difficult to answer without seeing data.
Is it working fine without variable?
Best Regards,
Samarth
If this post helps, please consider accepting it as the solution to help the other members find it more quickly.
Appreciate your Kudos!!
Connect on Linkedin
Covering the world! 9:00-10:30 AM Sydney, 4:00-5:30 PM CET (Paris/Berlin), 7:00-8:30 PM Mexico City
Check out the April 2024 Power BI update to learn about new features.
User | Count |
---|---|
97 | |
97 | |
81 | |
77 | |
66 |
User | Count |
---|---|
126 | |
105 | |
103 | |
81 | |
72 |