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

The Power BI DataViz World Championships are on! With four chances to enter, you could win a spot in the LIVE Grand Finale in Las Vegas. Show off your skills.

Reply
U156531
Helper V
Helper V

Adding years to Stacked Column Chart when there is no row for that year

I have a Stacked Column Chart where some years do not have a row of data. Is there a way to get the year to show up even though there isn't a row for that year in the table?

 

Thanks

1 ACCEPTED SOLUTION
SamWiseOwl
Super User
Super User

Hi @U156531 

Create a table with all the items you need, join to the existing date, then use this years column in the visual.

Go to the Columns section,use the drop down and choose Show items with No Data.

SamWiseOwl_1-1722953581901.pngSamWiseOwl_2-1722953621027.png

 

 

Here is a blog on creating a calendar table: https://www.wiseowl.co.uk/blog/s2947/calendarauto-table.htm

If you have no date, copy the code and replace calendar auto with
Calendar("01 Jan 2023", "31 Dec 2024") or what ever start and end date you like 🙂

SamWiseOwl_0-1722953542332.png

 


If you are happy with this answer please mark as a solution for others to find !

Kudos are always appreciated! Check out our free Power BI video courses.

View solution in original post

1 REPLY 1
SamWiseOwl
Super User
Super User

Hi @U156531 

Create a table with all the items you need, join to the existing date, then use this years column in the visual.

Go to the Columns section,use the drop down and choose Show items with No Data.

SamWiseOwl_1-1722953581901.pngSamWiseOwl_2-1722953621027.png

 

 

Here is a blog on creating a calendar table: https://www.wiseowl.co.uk/blog/s2947/calendarauto-table.htm

If you have no date, copy the code and replace calendar auto with
Calendar("01 Jan 2023", "31 Dec 2024") or what ever start and end date you like 🙂

SamWiseOwl_0-1722953542332.png

 


If you are happy with this answer please mark as a solution for others to find !

Kudos are always appreciated! Check out our free Power BI video courses.

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 MSCUST for a $150 discount!

FebPBI_Carousel

Power BI Monthly Update - February 2025

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

Feb2025 Sticker Challenge

Join our Community Sticker Challenge 2025

If you love stickers, then you will definitely want to check out our Community Sticker Challenge!

Feb2025 NL Carousel

Fabric Community Update - February 2025

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