Convert hours in decimal form to hours/minutes

Hello everyone,
I record the running time of my devices. However, as soon as the value rises above 60 minutes, the hour is displayed in the form of a decimal number. So e.g. B. 2.79 But I would like to have the reasonable output in hours and minutes, i.e.: 2.47 hours.
How do I fix that? I’ve been looking since yesterday, but I can’t find it.
My code looks like this:

import "timezone"
option location = timezone.location(name: "Europe/Berlin")
from(bucket: "DBANDY1")
|> range(start: v.timeRangeStart, stop: v.timeRangeStop)
|> filter(fn: (r) => r["_measurement"] == "Laufzeit_Imac")
|> filter(fn: (r) => r["_field"] == "value")
|> aggregateWindow(every: 24h, fn: sum, timeSrc: "_start")

Does this help?

https://community.grafana.com/t/output-seconds-in-hours-minutes-no-date/82825/7?u=grant2

Solved in this thread.

1 Like