cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
fernandoC
Helper V
Helper V

Unable to use Legend on Stacked bar chart

Hi folks,

 

I've been trying to set a stacked bar chart just as the one below: 

 

stacked.PNG

 

the issue I've been having is when I place a label on the "Legend" field the visualization produce an error:  "The group in the primary axis and the secondary axis overlap.....". From what I found online, this should be a transient error but even after removing or switching the labels the issue still persist. Any recommendations would be greatly appreciated. 

 

Best, 

1 ACCEPTED SOLUTION

Hi @fernandoC ,

 

Thanks for sharing the file.

I made changes to your pbix and updated it. You can acess it from here:

https://wetransfer.com/downloads/cb9443e14ff1f60ab0b560bfbd5339c020200616154706/dd58df37ed894339ca11...

 

Thanks,

Pragati





If this helps, Appreciate a KUDOS!
Did I answer your question? Mark my post as a solution!


Proud to be a Super User!




View solution in original post

14 REPLIES 14
Pragati11
Super User III
Super User III

Hi @fernandoC ,

 

Can you share some screenshots around the chart you are using in Power BI and the error you are getting?

 

Thanks,

Pragati





If this helps, Appreciate a KUDOS!
Did I answer your question? Mark my post as a solution!


Proud to be a Super User!




Hi @Pragati11 

 

Thank you for your help!.

 

15.PNG16.PNG

 

When only using the axis and values field the visualization works fine. 

 

17.PNG

 

Once the legend comes in I receive the above error message. 

 

if you need further information, please let me know.

 

Best,

Hi @fernandoC ,

 

Does these 3 columns - Loaction, Training Category, Training Participants..; come from the same table?

Can you share some sample rows for these columns in the table?

It seems to me there is some data relationship issue.

 

Thanks,

Pragati





If this helps, Appreciate a KUDOS!
Did I answer your question? Mark my post as a solution!


Proud to be a Super User!




Hi @Pragati11 ,

 

The data is coming from the same table except the measure. 

 

18.PNG19.PNG20.PNG

Let me know if any additional info is required. 

 

Best, 

 

Hi @fernandoC ,

 

I see that your measure is created using 2 different columns from different tables.

 

What's in the other table "Training Costs"? Do you have a relationship between these 2 tables?

Can you paste scteenshot of your data model?

 

Thanks,

Pragati





If this helps, Appreciate a KUDOS!
Did I answer your question? Mark my post as a solution!


Proud to be a Super User!




Hi @Pragati11 ,

 

Yes of course!

 

22.PNG

@Pragati11 

 

Not sure how I can upload the pbix file privately here.

 

Best,

Hi @fernandoC ,

 

Use Weshare to create a downloadable link or may be dropbox. Then share the link.

 

Thanks,

Pragati





If this helps, Appreciate a KUDOS!
Did I answer your question? Mark my post as a solution!


Proud to be a Super User!




Hi @fernandoC ,

 

Thanks for sharing the file.

I made changes to your pbix and updated it. You can acess it from here:

https://wetransfer.com/downloads/cb9443e14ff1f60ab0b560bfbd5339c020200616154706/dd58df37ed894339ca11...

 

Thanks,

Pragati





If this helps, Appreciate a KUDOS!
Did I answer your question? Mark my post as a solution!


Proud to be a Super User!




View solution in original post

Hi @Pragati11 ,

 

thank you very much!. 

 

What was causing the problem? I can see that you used a calculated column instead of a measure. 

 

Best,

Hi @fernandoC ,

 

A measure is a summarised figure, which was not chnaging it's value for different categories that were moved in the LEGEND area of the chart.

So, I created a column and it plots a different value for a different legend value.

 

Thanks,

Pragati





If this helps, Appreciate a KUDOS!
Did I answer your question? Mark my post as a solution!


Proud to be a Super User!




Thank you very much @Pragati11 

 

Makes total sense now!. 

 

Works like a charm. 

 

Best,

Hi @fernandoC ,

 

Is it possible to share your pbix file? You can share privately if not here publicly.

 

Thanks,

Pragati





If this helps, Appreciate a KUDOS!
Did I answer your question? Mark my post as a solution!


Proud to be a Super User!




Helpful resources

Announcements
PBI User Groups

Welcome to the User Group Public Preview

Check out new user group experience and if you are a leader please create your group

April Update

Check it Out!

Click here to read more about the April 2021 Updates!

secondImage

The largest Power BI virtual conference

100+ sessions, 100+ speakers, Product managers, MVPs, and experts. All about Power BI. Attend online or watch the recordings.

secondImage

Experience what’s next for Power BI

See the latest Power BI innovations, updates, and demos from the Microsoft Business Applications Launch Event.