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

Need to calculate revenue for unconventional business day (hours are 4:00am - 3:59am).

I am experiencing an issue when trying to calculate the revenue for a given business day.  Here is an example of what timeframe constitutes a business day:

 

8/7/2022 4:00am - 8/8/2022 3:59AM - This would be for business day 8/7/2022.

 

The data i am working with is all labeled by calendar day.  The data also has a column for hour which i believe should prove to be helpful.  My issue is that i do not know how to manipulate my DAX to give me the revenue for my business day and label it with the correct day.

 

Here is an example of the data i am working with:

 

Fulfilled_0-1659992288805.png

 

Here is the query i am using which works if my business day aligned with the calendar day:

 

Coin In Sum By Date (Calendar) = CALCULATE(SUM('Headcount SP Data'[Coin In Sum By Hour]), ALLEXCEPT('Headcount SP Data','Headcount SP Data'[dtTime]))
 
Is it possible to produce the data that would say:
 
Coin In Sum By Date (Business) = SUM of Coin In Sum By Hour WHERE iHour = 4-24 on Day 1 and 0-3 on Day 2
(All while tagging this result as Day 1)

 

1 REPLY 1
amitchandak
Super User
Super User

@Fulfilled , Refer if this blog can help

https://exceleratorbi.com.au/calculating-business-hours-using-dax/

Share with Power BI Enthusiasts: Full Power BI Video (20 Hours) YouTube
Microsoft Fabric Series 60+ Videos YouTube
Microsoft Fabric Hindi End to End YouTube

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!

December 2025 Power BI Update Carousel

Power BI Monthly Update - December 2025

Check out the December 2025 Power BI Holiday Recap!

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.