Back

Explore Courses Blog Tutorials Interview Questions
0 votes
1 view
in BI by (17.6k points)

I am working with PowerBI and would like to show time duration in the format "hh:mm: ss".

I know how to convert duration (seconds, minutes, hours, etc.) into a string in the format "hh:mm: ss" using DAX, but is it possible to get this format as labels in a bar chart for example?

Searching on the internet it seems this is not possible, but I was not able to find a definite answer.

Below is a picture where the added red text shows the desired result (right now the red text is static and manually added).

In short: Is it possible to show time duration in the format "hh:mm:ss" in charts in PowerBI?

1 Answer

0 votes
by (47.2k points)
  • This does not seem to be possible at the moment as that measures do not return integer or decimal values which can not be used as values in bar/line charts.

  • The best you can do is to add the measure as a tooltip.

  • So given a measure [Duration in Seconds], which returns an integer or decimal value, create a new measure:

Time is duration = TIME(0, 0, [Duration in Seconds])

  • Format this measure as Date Time > HH:mm:ss.

  • now, create your bar chart using [Duration in Seconds] as values, and add [Duration as Time] as tooltips:

  • If you need to have data labels formatted as HH:mm:ss, consider upvoting this Power BI idea.
Welcome to Intellipaat Community. Get your technical queries answered by top developers!

28.4k questions

29.7k answers

500 comments

94k users

Browse Categories

...