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

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.

Reply
Kostas
Helper IV
Helper IV

Bar Char Visual formatting

Hello, 
I am still learning the Power BI and how I can take the most out of the visuals available. 

At the moment I do have a table that contain two different columns as seems below. Both columns have the same values available but it can have different value per code in each column. 

CodeRating 1Rating 2

2244

EffectiveNot Effective
2425Needs ImprovementNeeds Improvement
5233Needs ImprovementEffective

 

My end goal is to produce a bar chart that in the axis will contain the different rating values (e.g. effective, Needs Improvement, Not Effective) and it will have two columns to count the codes for each rating (see example below)

Kostas_1-1594633842984.png

Is it possible to produce the specific graph? Ideally, I would prefer NOT to produce it with measures because I am using a table below that shows more information regarding the codes, that means that when the user will select the column or the x axis value the table will show the information regarding the codes. With a measure I will not be able to do that.

 

Thanks

Kostas

 

1 ACCEPTED SOLUTION
harshnathani
Community Champion
Community Champion

Hi @Kostas ,

 

You will need to unpivot your columns.

 

Select the code Column and then click on Unpivot Other Columns

 

2.JPG

 

 

 

Youl will get the following table

 

2.JPG

 

Then drag the columns to get the output.

 

 

1.jpg

 


Regards,

Harsh Nathani


Appreciate with a Kudos!! (Click the Thumbs Up Button)

Did I answer your question? Mark my post as a solution!

 

View solution in original post

3 REPLIES 3
harshnathani
Community Champion
Community Champion

Hi @Kostas ,

 

You will need to unpivot your columns.

 

Select the code Column and then click on Unpivot Other Columns

 

2.JPG

 

 

 

Youl will get the following table

 

2.JPG

 

Then drag the columns to get the output.

 

 

1.jpg

 


Regards,

Harsh Nathani


Appreciate with a Kudos!! (Click the Thumbs Up Button)

Did I answer your question? Mark my post as a solution!

 

Helloo @harshnathani,

It worked perfectly, seems like an easy solution just needed some out of the box thinking. 

I got one more question, is it possible to specify the columns colour for each value in the x axis with a specific colour rather than specify only the type of the rating? 
For example the two columns generated for effective to be green, the two colours for needs improvement yellow etc.

 

Thank you in advance. 

If there is no way of doing that I will accept your previous answer as solution and close the topic.

 

Thanks

Kostas

Hi @Kostas ,

 

I do not think you can havecolous of of Bar changed based on Axis Values.

 

Regards,

Harsh Nathani

 

 

 

 

 

Helpful resources

Announcements
Microsoft Fabric Learn Together

Microsoft Fabric Learn Together

Covering the world! 9:00-10:30 AM Sydney, 4:00-5:30 PM CET (Paris/Berlin), 7:00-8:30 PM Mexico City

PBI_APRIL_CAROUSEL1

Power BI Monthly Update - April 2024

Check out the April 2024 Power BI update to learn about new features.

April Fabric Community Update

Fabric Community Update - April 2024

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