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
Anonymous
Not applicable

Cannot create chart from table - what is wrong with me!

How do I turn the data in this table into a stacked column chart? The answer seems obvious but for the life of me I cannot seem to make it work.

 
1 ACCEPTED SOLUTION

If it is your raw data first unpivot

https://radacad.com/pivot-and-unpivot-with-power-bi

 

If this was matrix. In stacked visual

Drag date on-axis and column on Legend.

View solution in original post

5 REPLIES 5
Greg_Deckler
Super User
Super User

In Query Editor, select your first date column. Hold down Shift and select your last date column. Right click on any selected column and choose Unpiviot columns. Close and Apply. You should be good to go.


@ 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!:
The Definitive Guide to Power Query (M)

DAX is easy, CALCULATE makes DAX hard...
Anonymous
Not applicable

Thank you for your response.  So, I unpivoted the table (see below) but this does not appear to have given me the result I wanted. To create the chart, I put Financial Year in the Axis, Type in the Legend and Value in the Value.  The value was a count only of the type for each financial year, not the actual values shown in the column. What have I done wrong?

BICapture10.JPG

Thanks

Steve

Anonymous
Not applicable

Ignore this entry. I have figured out what I did wrong. The Value column was not set as a Whole Number. Once this was corrected the chart worked as required.

Thanks

Steve

Anonymous
Not applicable

This is the table

BICapture9.JPG

If it is your raw data first unpivot

https://radacad.com/pivot-and-unpivot-with-power-bi

 

If this was matrix. In stacked visual

Drag date on-axis and column on Legend.

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.