Join us at FabCon Atlanta from March 16 - 20, 2026, for the ultimate Fabric, Power BI, AI and SQL community-led event. Save $200 with code FABCOMM.
Register now!Calling all Data Engineers! Fabric Data Engineer (Exam DP-700) live sessions are back! Starting October 16th. Sign up.
I have a report that is generated by our Point-of-Sale system. The report has the date/time a check is opened and when it is closed.
Our business day for this report runs from 3:00AM - 2:59 AM. I need to add a date column to represent the business/transaction day.
Open Date/Time AFTER 1/1/2020 3:00:00 AM Close Date/Time BEFORE 1/2/2020 2:59:00 AM = Business Date of 1/1/2020.
Examples:
Open Date/Time Close Date/Time Business Date
1/1/2020 09:00:00 AM 1/1/2020 09:30:00 AM 1/1/2020
1/1/2020 11:00:00 PM 1/2/2020 01:30:00 AM 1/1/2020
1/2/2020 01:00:00 AM 1/2/2020 02:00:00 AM 1/1/2020
Solved! Go to Solution.
@djj13 , Try a new column like
Business Date =
Switch( true(),
hour([Open Date/Time]) >= 3 , [Open Date/Time].date , // or use date(year([Open Date/Time]), month([Open Date/Time]), day([Open Date/Time])) ,
hour([Close Date/Time]) < 3 ,[Open Date/Time].date -1,
[Open Date/Time].date
)
@djj13 , Try a new column like
Business Date =
Switch( true(),
hour([Open Date/Time]) >= 3 , [Open Date/Time].date , // or use date(year([Open Date/Time]), month([Open Date/Time]), day([Open Date/Time])) ,
hour([Close Date/Time]) < 3 ,[Open Date/Time].date -1,
[Open Date/Time].date
)
Thank you! This worked. I tried using [Open Date/Time].date but received a syntax error for the date function.
dj.
You can use a column expression like this to do that.
To learn more about Power BI, follow me on Twitter or subscribe on YouTube.
Join the Fabric FabCon Global Hackathon—running virtually through Nov 3. Open to all skill levels. $10,000 in prizes!
Check out the October 2025 Power BI update to learn about new features.