March 31 - April 2, 2025, in Las Vegas, Nevada. Use code MSCUST for a $150 discount! Early bird discount ends December 31.
Register NowBe one of the first to start using Fabric Databases. View on-demand sessions with database experts and the Microsoft product team to learn just how easy it is to get started. Watch now
Hi Guys,
I am creating a line and bar chart and my requirement is if i select "Sum" on a slicer, Bar should show the sum of products and line should show the sum of items. If i select "Count" on the slicer bar should show Count of products and Count of items on Line.
To simplyfy i want to make separate calculations for Bar and line with a single slicer selection.
Please help.
Regards,
Shashi
Solved! Go to Solution.
Hi @Shashi_Kant82 ,
Please follow these steps:
(1) Create a new measure
VALUE =
VAR _COUNT = COUNT('Table'[PROJECT])
VAR _TOTAL = SUM('Table'[SALES])
RETURN IF(VALUES(EX[SELECT])="COUNT",_COUNT,_TOTAL)
(2)Final output
Since there is no sample data, I made a simple example, if this does not help you, please provide sample data and the expected output.
Best Regards,
Gallen Luo
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
Hi @Shashi_Kant82 ,
Please follow these steps:
(1) Create a new measure
VALUE =
VAR _COUNT = COUNT('Table'[PROJECT])
VAR _TOTAL = SUM('Table'[SALES])
RETURN IF(VALUES(EX[SELECT])="COUNT",_COUNT,_TOTAL)
(2)Final output
Since there is no sample data, I made a simple example, if this does not help you, please provide sample data and the expected output.
Best Regards,
Gallen Luo
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
March 31 - April 2, 2025, in Las Vegas, Nevada. Use code MSCUST for a $150 discount!
Arun Ulag shares exciting details about the Microsoft Fabric Conference 2025, which will be held in Las Vegas, NV.
User | Count |
---|---|
115 | |
76 | |
57 | |
52 | |
44 |
User | Count |
---|---|
164 | |
116 | |
63 | |
57 | |
50 |