The ultimate Fabric, Power BI, SQL, and AI community-led learning event. Save €200 with code FABCOMM.
Get registeredEnhance your career with this limited time 50% discount on Fabric and Power BI exams. Ends September 15. Request your voucher.
Hi,
I'm trying to show values in clustered column chart in the below manner.
My client wants to see 100% for each Market listed in the chart instead of showing 100% for all markets. The value is derived from the Count of emps.
Any help on this would be really appreciated!!
Regards,
Mahesh
Solved! Go to Solution.
Hi, @Maheshguptaz
I briefly simulated some data to hopefully fit your needs.
Measure:
Percentage =
DIVIDE (
CALCULATE (
COUNT ( 'Table'[Emp ID] ),
FILTER (
ALL ( 'Table' ),
[Market] = SELECTEDVALUE ( 'Table'[Market] )
&& [Emp ID] = SELECTEDVALUE ( 'Table'[Emp ID] )
)
),
CALCULATE (
COUNT ( 'Table'[Emp ID] ),
FILTER ( ALL ( 'Table' ), [Market] = SELECTEDVALUE ( 'Table'[Market] ) )
)
)
Is this the result you expect, showing 100% by each market?
Best Regards,
Community Support Team _Charlotte
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
Hi, @Maheshguptaz
Can you provide some of the example data for testing? What do you expect the results to look like, and can you also show them in pictures?
Best Regards
Hi @v-zhangti ,
As you can see in the picture I posted in my message, I'm % of emps in each market. I didn't create any measure for this. I used the count of emps and showed the value as %GT of Emps on the chart.
The new requirement is that I need to show % of emps as 100% for each market instead of segregating the total value across markets.
Below is a measure that can help me do that but I'm looking for something more dynamic which can be used for all markets in a single measure.
Buildings = calculate( Count(Emp ID), Market = "Buildings")
Please let me know if we have a way to do this calculation for all markets in a dynamic way.
Regards,
Mahesh
Hi, @Maheshguptaz
I briefly simulated some data to hopefully fit your needs.
Measure:
Percentage =
DIVIDE (
CALCULATE (
COUNT ( 'Table'[Emp ID] ),
FILTER (
ALL ( 'Table' ),
[Market] = SELECTEDVALUE ( 'Table'[Market] )
&& [Emp ID] = SELECTEDVALUE ( 'Table'[Emp ID] )
)
),
CALCULATE (
COUNT ( 'Table'[Emp ID] ),
FILTER ( ALL ( 'Table' ), [Market] = SELECTEDVALUE ( 'Table'[Market] ) )
)
)
Is this the result you expect, showing 100% by each market?
Best Regards,
Community Support Team _Charlotte
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
@Maheshguptaz , a new Measure
assume you have measure for which you want this %
divide([measure], calculate([measure], removefilters(Table[Legend Column]))
Use the legend column in remove filters
@amitchandak there's no measure created for this. We're showing the % of grand total in the chart
User | Count |
---|---|
68 | |
63 | |
59 | |
54 | |
28 |
User | Count |
---|---|
182 | |
81 | |
64 | |
46 | |
41 |