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
Hnd12000
Frequent Visitor

Report of Quarterly data

How do you deal with uncomplete quarters in your reports ?
I don't like to show them while they are not complete, because it gives the impression that business is down (compared with previous quarters that were completed) but I don't find an easy way to filter them automatically only if they are not complete. 
(what I mean is that when I'm early March, I have available Jan and Feb only but if I display this as Q1, it is based on only 2 months when the other quarters showing are all based on 3 months sales)


On the other hand the ideal would be to be able to calculate a projected value for the current quarter, but this maybe too complicated.

5 REPLIES 5
v-shex-msft
Community Support
Community Support

Hi @Hnd12000,

You can also take a look at the following blog about use date function to manually define filter range, it is more flexible and not require a calendar table:

Time Intelligence "The Hard Way" (TITHW)  

Regards,

Xiaoxin Sheng

Community Support Team _ Xiaoxin
If this post helps, please consider accept as solution to help other members find it more quickly.
amitchandak
Super User
Super User

This how we use it

QTD Sales = CALCULATE(SUM(Sales[Sales Amount]),DATESQTD(('Date'[Date])))

Last QTD Sales = CALCULATE(SUM(Sales[Sales Amount]),DATESQTD(dateadd('Date'[Date],-1,QUARTER)))

If you want take last QTR complete

Last QTD Sales EOQ = CALCULATE(SUM(Sales[Sales Amount]),DATESQTD(ENDOFQUARTER(dateadd('Date'[Date],-1,QUARTER))))

 

All this need date table.To get the best of the time intelligence function. Make sure you have a date calendar and it has been marked as the date in model view. Also, join it with the date column of your fact/s.

Refer
https://radacad.com/creating-calendar-table-in-power-bi-using-dax-functions

 

Appreciate your Kudos. In case, this is the solution you are looking for, mark it as the Solution. In case it does not help, please provide additional information and mark me with @
Thanks. My Recent Blog -
https://community.powerbi.com/t5/Community-Blog/Winner-Topper-on-Map-How-to-Color-States-on-a-Map-wi...
https://community.powerbi.com/t5/Community-Blog/HR-Analytics-Active-Employee-Hire-and-Termination-tr...
https://community.powerbi.com/t5/Community-Blog/Power-BI-Working-with-Non-Standard-Time-Periods/ba-p...
https://community.powerbi.com/t5/Community-Blog/Comparing-Data-Across-Date-Ranges/ba-p/823601

Thanks Amitchandak, Last QTD sales EOQ does what I wanted.

The only thing is that with it, I can't use "legend" (that allowed me to split the sales by product families)  in my stacked area chart.

 

This is what I get when try :

Calculation error in measure 'DateTable'[Last QTD Sales EOQ]: Function 'DATEADD' expects a contiguous selection when the date column comes from a table on the 1-side of a bi-directional relationship.

 

In all time intellignce function you have use continous date. So you need to provide datetable[Date], refer my example. If you some issues. Let me know the new formula you tried.

with my variables  your formula end up to be  :
Last QTD Sales EOQ = CALCULATE(SUM(Merged[Total sales]),DATESQTD(ENDOFQUARTER(dateadd(DateTable[Date],-1,QUARTER))) )

But I can't get it to work splited by "product_line"

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.