Skip to main content
cancel
Showing results for 
Search instead for 
Did you mean: 

Compete to become Power BI Data Viz World Champion! First round ends August 18th. Get started.

Reply
NatalieTlash
New Member

Count Measure with same grand total for all categories in stacked column chart, THANK YOU

Hi! I am a big fan of this community! 🤗 I search all my Power BI questions in here and always have an answer from previusly asked questions. This time I am posting my own question because unfortunately couldn't find similar post. Appriciate a lot if you could help 🙂 🙂 🙂 I am really really stuck. 

 

I have EEs table with thousands of EEs for each period with below data:

PeriodEE#Profit Center  Grade

2020Q1

  1

  223
2020Q1  2  445
2020Q2  1  223
2020Q2  2  335
2020Q2  3  447

 

I also have a table with all EEs salary components:

PeriodEE#CategoryUSD

2020Q1

  1

Base Salary20000  
2020Q1  1Bonuses5000
2020Q1  2Base Salary40000  
2020Q1  2Bonuses4000
2020Q1  2Leasing500

 

I have a one to many connection between the 2 tables using combined column of period & EE#.

 

I now need to calculate average salary for every period which will be dinamic and I will be ably to slice/filter it by profit center and other parameters. So I used DIVIDE() measure, but my problem is when I present it in stacked collumn chart with Category as legend - I notice that the average salary is calculated separatly for each Category using total EEs in each caltegory - in the example 2 EEs in Base Salary, 2 in Bonuses and 1 in Leasing. I would like to have same total of EEs in every category - which is total EEs I have in each period - 2 in Q1, 3 in Q2. Is it possible? I tried ALL, ALLSELECTED, ALLEXCEPT.

 

Appriciate a lot for any direction!!!

Thank you

Natalie

1 ACCEPTED SOLUTION
Greg_Deckler
Community Champion
Community Champion

@NatalieTlash I'm not 100% what you want. Try making your relationship bi-directional? What is your measure formula and what is your expected output? 



Follow on LinkedIn
@ me in replies or I'll lose your thread!!!
Instead of a Kudo, please vote for this idea
Become an expert!: Enterprise DNA
External Tools: MSHGQM
YouTube Channel!: Microsoft Hates Greg
Latest book!:
DAX For Humans

DAX is easy, CALCULATE makes DAX hard...

View solution in original post

2 REPLIES 2
NatalieTlash
New Member

Thank you Greg! You are right, the issue was the relationship between the tables, it was bi directional and should be one direction! You are such a pro 😃

Greg_Deckler
Community Champion
Community Champion

@NatalieTlash I'm not 100% what you want. Try making your relationship bi-directional? What is your measure formula and what is your expected output? 



Follow on LinkedIn
@ me in replies or I'll lose your thread!!!
Instead of a Kudo, please vote for this idea
Become an expert!: Enterprise DNA
External Tools: MSHGQM
YouTube Channel!: Microsoft Hates Greg
Latest book!:
DAX For Humans

DAX is easy, CALCULATE makes DAX hard...

Helpful resources

Announcements
August Power BI Update Carousel

Power BI Monthly Update - August 2025

Check out the August 2025 Power BI update to learn about new features.

August 2025 community update carousel

Fabric Community Update - August 2025

Find out what's new and trending in the Fabric community.