cancel
Showing results for
Did you mean:

Earn a 50% discount on the DP-600 certification exam by completing the Fabric 30 Days to Learn It challenge.

Frequent Visitor

## Hide incomplete quarters in line chart

I've been struggling with this for hours and cannot seem to figure it out.

My issue is pretty straightforward. I have a line chart that shows data over the previous 4 years. One of the tables used is a financial table that loads data a month or two months behind. As of today, the data is loaded through November 2021. I need to hide 2021 - Q4 from the line chart until December data is loaded in.

It needs to be dynamic where I can do it and leave it - without having to come back every month or so to change something.

2 ACCEPTED SOLUTIONS
Solution Sage

Hi:

If you can add to your date table an index number for each Quarter. E.G.,

2018 Q 1 = 201801  0r  1

2018Q2 =201802     Or 2

.... 2021Q4 = 202104   or  16

This column is named index in this example

Completed Qtr  =

VAR ThisQtrID =

LOOKUPVALUE(Dates[Index], Dates[Date], TODAY())

RETURN Dates[Index] < ThisQtrID

//returns TRUE() if the quarter is in the past and complete

set filter appropriately - set to TRUE //

There are other ways of doing it like having a date calendar with offset so 0 is the current quarter, so you filter not to include it. There are date tables available on the internet. If you need more help let me know.

Thanks..

Super User

@Booyah It is funny you asked this, I was about to do a video on this in the next few days, maybe I will prioritize it. Subscribe to my youtube channel to stay updated (link below), if you found a solution before that, great.

Learn about conditional formatting at Microsoft Reactor

My latest blog post The Power of Using Calculation Groups with Inactive Relationships (Part 1) (perytus.com) I would  Kudos if my solution helped. 👉 If you can spend time posting the question, you can also make efforts to give Kudos to whoever helped to solve your problem. It is a token of appreciation!

Visit us at https://perytus.com, your one-stop-shop for Power BI-related projects/training/consultancy.

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.

9 REPLIES 9
Frequent Visitor

I've been struggling with this for hours and cannot seem to figure it out.

My issue is pretty straightforward. I have a line chart that shows data over the previous 4 years. One of the tables used is a financial table that loads data a month or two months behind. As of today, the data is loaded through November 2021. I need to hide 2021 - Q4 from the line chart until December data is loaded in.

It needs to be dynamic where I can do it and leave it - without having to come back every month or so to change something.

Frequent Visitor

I've been struggling with this for hours and cannot seem to figure it out.

My issue is pretty straightforward. I have a line chart that shows data over the previous 4 years. One of the tables used is a financial table that loads data a month or two months behind. As of today, the data is loaded through November 2021. I need to hide 2021 - Q4 from the line chart until December data is loaded in.

It needs to be dynamic where I can do it and leave it - without having to come back every month or so to change something.

Super User

How do you know that/when a quarter is complete?

Super User

Awesome. Thanks for subscribing. Almost there 🙂

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.

Super User

@Booyah It is funny you asked this, I was about to do a video on this in the next few days, maybe I will prioritize it. Subscribe to my youtube channel to stay updated (link below), if you found a solution before that, great.

Learn about conditional formatting at Microsoft Reactor

My latest blog post The Power of Using Calculation Groups with Inactive Relationships (Part 1) (perytus.com) I would  Kudos if my solution helped. 👉 If you can spend time posting the question, you can also make efforts to give Kudos to whoever helped to solve your problem. It is a token of appreciation!

Visit us at https://perytus.com, your one-stop-shop for Power BI-related projects/training/consultancy.

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.

Frequent Visitor

That would be awesome. Just subscribed to the channel and I look forward to seeing that video!

Solution Sage

Hi:

If you can add to your date table an index number for each Quarter. E.G.,

2018 Q 1 = 201801  0r  1

2018Q2 =201802     Or 2

.... 2021Q4 = 202104   or  16

This column is named index in this example

Completed Qtr  =

VAR ThisQtrID =

LOOKUPVALUE(Dates[Index], Dates[Date], TODAY())

RETURN Dates[Index] < ThisQtrID

//returns TRUE() if the quarter is in the past and complete

set filter appropriately - set to TRUE //

There are other ways of doing it like having a date calendar with offset so 0 is the current quarter, so you filter not to include it. There are date tables available on the internet. If you need more help let me know.

Thanks..

Super User

Hi @Booyah

Can you post sample data as text and expected output?
Not enough information to go on;

The most important parts are:
1. Sample data as text, use the table tool in the editing bar
2. Expected output from sample data
3. Explanation in words of how to get from 1. to 2.

Frequent Visitor

Here is a super brief mock-up of what I want to see as the output. I am showing the total sales across several years 2018-present by each quarter. What I want to be able to do is create a calculated column as 'Complete Quarter' to set months in a quarter to "FALSE" if the quarter is not full.

 CustomerID Date of Sale State Total Sales Complete Quarter 1 November 1, 2021 NY \$10 FALSE 2 October 1, 2021 NY \$20 FALSE 3 September 1, 2021 CA \$3 TRUE 4 August 1, 2021 WI \$5 TRUE 5 July 1, 2021 TN \$7 TRUE

This table is loaded once a month. When it's loaded in, it's always a month behind. So the December 2021 data will not be loaded in until the next week or so.

If I have a calculated column like this, then I can set it to filter that line chart to only show "TRUE" values which will solve my issue of showing an incomplete quarter.

Announcements

#### New forum boards available in Real-Time Intelligence.

Ask questions in Eventhouse and KQL, Eventstream, and Reflex.

#### Power BI Monthly Update - May 2024

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

#### Fabric certifications survey

Certification feedback opportunity for the community.

Top Solution Authors
Top Kudoed Authors