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

Get inspired! Check out the entries from the Power BI DataViz World Championships preliminary rounds and give kudos to your favorites. View the vizzies.

Reply
Anonymous
Not applicable

Create column chart from SharePoint Online list with data modelling

Hi,

I am new to Power BI.

My data set looks like this:

Soumo777_0-1621861076478.png

I want my column graph to look like this:

Soumo777_1-1621861115822.png

How do I achieve this?

Thanks in advance for all the help.

1 ACCEPTED SOLUTION

@Anonymous , No pets on axis and a measure 

measure = count(Table[Pets]) on values should do

 

If you want a table

 

new Table  =

summarize(Table, Table[pets], "Count", count(Table[Pets]))

Full Power BI Video 20 Hours YouTube
Microsoft Fabric Series 60+ Videos YouTube
Microsoft Fabric Hindi End to End YouTube

View solution in original post

4 REPLIES 4
amitchandak
Super User
Super User

@Anonymous , This counts pets with pets on-axis.

With conditional formatting measure with field value option

 

Color = Switch(true(),

max(Table[Pets] ="Cat" , "Red",

max(Table[Pets] ="Dog" , "Yellow",

// Add other

"Green" //default

 

)

 

For conditional formatting refer PowerBI Abstract Thesis: How to do conditional formatting by measure and apply it on pie?: https://youtu.be/RqBb5eBf_I4

Full Power BI Video 20 Hours YouTube
Microsoft Fabric Series 60+ Videos YouTube
Microsoft Fabric Hindi End to End YouTube
Anonymous
Not applicable

Hi @amitchandak ,

But in order to achieve this, I think my data source should look like this:

Soumo777_0-1621862683031.png

How do I model it in this way?

@Anonymous , No pets on axis and a measure 

measure = count(Table[Pets]) on values should do

 

If you want a table

 

new Table  =

summarize(Table, Table[pets], "Count", count(Table[Pets]))

Full Power BI Video 20 Hours YouTube
Microsoft Fabric Series 60+ Videos YouTube
Microsoft Fabric Hindi End to End YouTube
Anonymous
Not applicable

@amitchandak Thanks a ton! Worked perfectly.

Helpful resources

Announcements
Las Vegas 2025

Join us at the Microsoft Fabric Community Conference

March 31 - April 2, 2025, in Las Vegas, Nevada. Use code FABINSIDER for a $400 discount!

FebPBI_Carousel

Power BI Monthly Update - February 2025

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

March2025 Carousel

Fabric Community Update - March 2025

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

Top Solution Authors
Top Kudoed Authors