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

Learn from the best! Meet the four finalists headed to the FINALS of the Power BI Dataviz World Championships! Register now

Reply
Digger
Post Patron
Post Patron

hh:mm:ss chart in pbi

How to create same excel chart in pbi?

 

Digger_0-1668698532495.png

 

1 ACCEPTED SOLUTION

@PhilipTreacy , you wrong, PBI does, i found solution

Digger_0-1668753179261.png

All you need is use this measure

_Measure HH:mm:SS =
VAR vHoursDecimal = 1111,12 // HOURS!!! not seconds
VAR vHours = INT ( vHoursDecimal )
VAR vMinutesDecimal = 60 * ( vHoursDecimal - vHours )
VAR vMinutes = INT ( vMinutesDecimal )
VAR vSeconds = ROUND ( 60 * ( vMinutesDecimal - vMinutes ), 0 )
VAR vHH = IF ( LEN ( vHours ) = 1, "0" & vHours, vHours )
VAR vMM = IF ( LEN ( vMinutes ) = 1, "0" & vMinutes, vMinutes )
VAR vSS = IF ( LEN ( vSeconds ) = 1, "0" & vSeconds, vSeconds )
RETURN
    CONVERT ( vHH & vMM & vSS, INTEGER )

 

 

and then change measure fomating, just typing 00:00:00

Digger_0-1668757963331.png

 

View solution in original post

4 REPLIES 4
PhilipTreacy
Super User
Super User

Hi @Digger 

 

PBI won't plot time on the Y axis like that.  The best you'll get is this

cbrt.png

 

regards

 

Phil



Did I answer your question? Then please mark my post as the solution.
If I helped you, click on the Thumbs Up to give Kudos.


Blog :: YouTube Channel :: Connect on Linkedin


Proud to be a Super User!


@PhilipTreacy , you wrong, PBI does, i found solution

Digger_0-1668753179261.png

All you need is use this measure

_Measure HH:mm:SS =
VAR vHoursDecimal = 1111,12 // HOURS!!! not seconds
VAR vHours = INT ( vHoursDecimal )
VAR vMinutesDecimal = 60 * ( vHoursDecimal - vHours )
VAR vMinutes = INT ( vMinutesDecimal )
VAR vSeconds = ROUND ( 60 * ( vMinutesDecimal - vMinutes ), 0 )
VAR vHH = IF ( LEN ( vHours ) = 1, "0" & vHours, vHours )
VAR vMM = IF ( LEN ( vMinutes ) = 1, "0" & vMinutes, vMinutes )
VAR vSS = IF ( LEN ( vSeconds ) = 1, "0" & vSeconds, vSeconds )
RETURN
    CONVERT ( vHH & vMM & vSS, INTEGER )

 

 

and then change measure fomating, just typing 00:00:00

Digger_0-1668757963331.png

 

I don't think this quite works. It interprets your values as integers and that doesn't log well on the Y axis. The convert function at the end just concatenates the 3 parts into a single integer. So 59 minutes becomes 5900, 1 hour becomes 10000, and they plot as integers at those values. Your graph is then skewed.

@Digger 

 

Care to share your solution so we can see how you did it?

 

Regards

 

Phil



Did I answer your question? Then please mark my post as the solution.
If I helped you, click on the Thumbs Up to give Kudos.


Blog :: YouTube Channel :: Connect on Linkedin


Proud to be a Super User!


Helpful resources

Announcements
Join our Fabric User Panel

Join our Fabric User Panel

Share feedback directly with Fabric product managers, participate in targeted research studies and influence the Fabric roadmap.

February Power BI Update Carousel

Power BI Monthly Update - February 2026

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