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

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.

Reply
askspepsi
Helper II
Helper II

{Direct Query} Change to Timeformat and Rounddown to nearest.

hi everyone,

I have an data output in my sql table in number format, when trying to calcuate the differentiate output comes in number format but output required is below.

 

11.35 to 11:21 and should rounddown to 11:00

11.65 to 11:39 and should rounddown to 11:30

12:00 to 12:00 and should not rounddown to 12:00

1 ACCEPTED SOLUTION
FrankAT
Community Champion
Community Champion

Hello @askspepsi ,

If I got your logic correctly, try the following forms in new columns:

Half hour = 
ROUND('Table'[Value] / 24 * 48,0) / 48 

Desired Output = 
IF(
    MINUTE('Table'[Value] / 24) <= 30 , 
    ROUND('Table'[Value] , 0 ) / 24 , 
    ROUND('Table'[Value] / 24 * 48 , 0 ) / 48
)

10-08-_2020_17-27-03.png

Greetings FrankAT

View solution in original post

4 REPLIES 4
FrankAT
Community Champion
Community Champion

Hello @askspepsi ,

If I got your logic correctly, try the following forms in new columns:

Half hour = 
ROUND('Table'[Value] / 24 * 48,0) / 48 

Desired Output = 
IF(
    MINUTE('Table'[Value] / 24) <= 30 , 
    ROUND('Table'[Value] , 0 ) / 24 , 
    ROUND('Table'[Value] / 24 * 48 , 0 ) / 48
)

10-08-_2020_17-27-03.png

Greetings FrankAT

@FrankAT

sorry for the late reply,

Thanks for the update. this is the extact output i required.

regards

askspepsi

amitchandak
Super User
Super User

@askspepsi , check if you can create a column suggested in this post

https://community.powerbi.com/t5/Desktop/Round-up-time-to-next-hour/td-p/701404

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

@amitchandak 

this is in time format where i cann't change.

Helpful resources

Announcements
October Power BI Update Carousel

Power BI Monthly Update - October 2025

Check out the October 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.

Top Kudoed Authors