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

The Power BI Data Visualization World Championships is back! Get ahead of the game and start preparing now! Learn more

Reply
Shannon-COTR
Regular Visitor

Remove Gaps When Comparing Year over Year

I'm trying to create a line graph that compares our weekly (Sunday) attendance year-over-year. My raw data contains unique dates for each Sunday from 2019-2023 as well as a caculated week number. Power BI has also automatically broken the date data down into years, quarters, months and days.

 

When I create the line graph with just the week numbers along the x-axis, it works perfectly. If I add the months in to make it a little easier for my staff to identify what they're looking at (most people don't know off the bat what time of year week 32 falls into), there are then large gaps anytime a week falls into a different month (e.g. week 5 is sometimes the last week of January and other times the first week of February, depending on the year).

Is there a way to have the line chart continuous so that it's easier to see the trends, but still be able to show the months?


Here's a screenshot with the months included in the x-axis and the resulting gaps:

ShannonCOTR_0-1691516899433.png

 

 

Here's a screenshot with just the weeks; the line graph is much easier to read except that it's far more difficult for my staff to be able to tell what time of year they're looking at:

ShannonCOTR_1-1691516980668.png

 

3 REPLIES 3
parry2k
Super User
Super User

@Shannon-COTR then you should create a measure that you want to use on values and as suggested add +0 to it.

 

👉 Learn Power BI and Fabric - subscribe to our YT channel - @PowerBIHowTo

If my solution proved useful, I'd be delighted to receive Kudos. When you put effort into asking a question, it's equally thoughtful to acknowledge and give Kudos to the individual who helped you solve the problem. It's a small gesture that shows appreciation and encouragement! ❤️



Subscribe to the @PowerBIHowTo YT channel for an upcoming video on List and Record functions in Power Query!!

Learn Power BI and Fabric - subscribe to our YT channel - Click here: @PowerBIHowTo

If my solution proved useful, I'd be delighted to receive Kudos. When you put effort into asking a question, it's equally thoughtful to acknowledge and give Kudos to the individual who helped you solve the problem. It's a small gesture that shows appreciation and encouragement! ❤


Did I answer your question? Mark my post as a solution. Proud to be a Super User! Appreciate your Kudos 🙂
Feel free to email me with any of your BI needs.

parry2k
Super User
Super User

@Shannon-COTR whatever measure you are using on values just add zero to it.

 

Measure = COUNTROWS ( Table ) + 0

 

👉 Learn Power BI and Fabric - subscribe to our YT channel - @PowerBIHowTo

If my solution proved useful, I'd be delighted to receive Kudos. When you put effort into asking a question, it's equally thoughtful to acknowledge and give Kudos to the individual who helped you solve the problem. It's a small gesture that shows appreciation and encouragement! ❤️



Subscribe to the @PowerBIHowTo YT channel for an upcoming video on List and Record functions in Power Query!!

Learn Power BI and Fabric - subscribe to our YT channel - Click here: @PowerBIHowTo

If my solution proved useful, I'd be delighted to receive Kudos. When you put effort into asking a question, it's equally thoughtful to acknowledge and give Kudos to the individual who helped you solve the problem. It's a small gesture that shows appreciation and encouragement! ❤


Did I answer your question? Mark my post as a solution. Proud to be a Super User! Appreciate your Kudos 🙂
Feel free to email me with any of your BI needs.

Thanks, but I'm not using any calculated measures at all so I don't think that this would work.

Helpful resources

Announcements
Power BI DataViz World Championships

Power BI Dataviz World Championships

The Power BI Data Visualization World Championships is back! Get ahead of the game and start preparing now!

November Power BI Update Carousel

Power BI Monthly Update - November 2025

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

FabCon Atlanta 2026 carousel

FabCon Atlanta 2026

Join us at FabCon Atlanta, March 16-20, for the ultimate Fabric, Power BI, AI and SQL community-led event. Save $200 with code FABCOMM.