# How to convert HH:MM:SS to just HH:MM?

**URL:** <https://community.glideapps.com/t/how-to-convert-hhss-to-just-hh-mm/51152>\
**Category:** Ask for Help\
**Created:** [October 7, 2022, 6:26pm UTC](https://community.glideapps.com/t/how-to-convert-hhss-to-just-hh-mm/51152 "2022-10-07T18:26:58Z")\
**Posts on this page:** 20\
**Page:** 2

<div class="post-metadata">

**Author:** ![Jeff\_Hager](https://sea2.discourse-cdn.com/flex002/user_avatar/community.glideapps.com/jeff_hager/32/43_2.png) [@Jeff\_Hager](https://community.glideapps.com/u/Jeff_Hager)\
**Post date:** [October 8, 2022, 12:34am UTC](https://community.glideapps.com/t/how-to-convert-hhss-to-just-hh-mm/51152/21 "2022-10-08T00:34:56Z")

</div>

I think this could be tricky, mainly because you are using a glide chart and the chart is displaying the duration which is a decimal number with a friendly format on top of it. Since it’s still a number, the chart will properly sum the decimal numbers for you, but still display the friendly duration format.

I can use a javascript column remove seconds and reformat, but it’s essentially a string instead of a number, so the chart won’t be able to properly sum the durations while retaining the format.

![image](https://us1.discourse-cdn.com/flex002/uploads/glideapps/original/3X/1/b/1b655d83510d30e13d6f196e0a847ecb71d61a4b.png)

It looks good in the data, but doesn’t translate well in the chart.

 ![image](https://us1.discourse-cdn.com/flex002/uploads/glideapps/original/3X/b/a/ba224ab6792f8e2e54757c1c78f404798ca59346.png)

Unfortunately, I can’t really think of good way to do this. The native duration formatting is applied on top of the underlying decimal number, for display purposes, post calculation. We are trying to apply our own formatting before the chart calculations are performed, which breaks the underlying numeric value. Because of that the chart will not work correctly. I think Glide would have to allow for an option on the duration column to show or hide seconds which would then apply after the chart has done it’s calculations.

---

<div class="post-metadata">

**Author:** ![Darren\_Murphy](https://sea2.discourse-cdn.com/flex002/user_avatar/community.glideapps.com/darren_murphy/32/47326_2.png) [@Darren\_Murphy](https://community.glideapps.com/u/Darren_Murphy)\
**Post date:** [October 8, 2022, 1:11am UTC](https://community.glideapps.com/t/how-to-convert-hhss-to-just-hh-mm/51152/22 "2022-10-08T01:11:11Z")

</div>

> [@Hassan\_Nadeem](#):
>
> Thanks for sharing that so quick. This is what I have got using your code.

Sorry, it was late last night when I posted that and I was on my way to bed, so I didn’t have time to elaborate. But if you’d read the post I linked to, you’d have seen that code column accepts an integer value as input (number of minutes).

So to use it and get the correct results, you’d first need to convert your duration into a number of minutes with a Math column. Or if your current duration is the result of a math column, adjust the formula to output integer minutes instead of a duration - eg. `Round((End - Start)*1440)`. Then the code column will give you the correct results.

That said, having now read the rest of the responses in the thread, it’s still not going to help for your _actual_ use case, because it will be returning a string.

Personally, I’d use quickchart. Then you can put whatever you want on the chart, anywhere on the chart.

---

<div class="post-metadata">

**Author:** ![Hassan\_Nadeem](https://sea2.discourse-cdn.com/flex002/user_avatar/community.glideapps.com/hassan_nadeem/32/72956_2.png) [@Hassan\_Nadeem](https://community.glideapps.com/u/Hassan_Nadeem)\
**Post date:** [October 8, 2022, 1:36am UTC](https://community.glideapps.com/t/how-to-convert-hhss-to-just-hh-mm/51152/23 "2022-10-08T01:36:39Z")

</div>

Thanks @Jeff_Hager for taking out time to experiment this and thanks @Darren_Murphy for the code. Quickchart was my last option since I wanted to do something native on Glide. That’s unfortunate that this can’t be done natively on Glide ☹

But lets see what @Uzo has in his mind since he is confident enough it can still be achieved through Glide 😃

> [@Uzo](#):
>
> glide has a great time conversion column… and an Excel formulas column… use it…

---

<div class="post-metadata">

**Author:** ![Darren\_Murphy](https://sea2.discourse-cdn.com/flex002/user_avatar/community.glideapps.com/darren_murphy/32/47326_2.png) [@Darren\_Murphy](https://community.glideapps.com/u/Darren_Murphy)\
**Post date:** [October 8, 2022, 1:50am UTC](https://community.glideapps.com/t/how-to-convert-hhss-to-just-hh-mm/51152/24 "2022-10-08T01:50:14Z")

</div>

I suspect that Uzo was referring to the Format Date plugin. Two points I’d make about that:

- It won’t help you in this case because it returns a string. And so you will be back to square one.
- [Use it at your own risk](https://community.glideapps.com/t/time-format/50074/8)

---

<div class="post-metadata">

**Author:** ![Uzo](https://sea2.discourse-cdn.com/flex002/user_avatar/community.glideapps.com/uzo/32/22639_2.png) [@Uzo](https://community.glideapps.com/u/Uzo)\
**Post date:** [October 8, 2022, 1:18pm UTC](https://community.glideapps.com/t/how-to-convert-hhss-to-just-hh-mm/51152/25 "2022-10-08T13:18:15Z")

</div>

here you go… no problem 😉

 ![Screen Shot 2022-10-08 at 9.15.51 AM](https://us1.discourse-cdn.com/flex002/uploads/glideapps/original/3X/b/6/b6c0beead56728c3ce2df7f37db4075ff4ef6af2.jpeg)

 ![Screen Shot 2022-10-08 at 9.17.43 AM](https://us1.discourse-cdn.com/flex002/uploads/glideapps/original/3X/1/2/1258871a7ef8a498c0c94e890272ce8026320293.jpeg)

you guys are overthinking this problem… LOL

---

<div class="post-metadata">

**Author:** ![NFNHello](https://sea2.discourse-cdn.com/flex002/user_avatar/community.glideapps.com/nfnhello/32/3371_2.png) [@NFNHello](https://community.glideapps.com/u/NFNHello)\
**Post date:** [October 8, 2022, 1:46pm UTC](https://community.glideapps.com/t/how-to-convert-hhss-to-just-hh-mm/51152/26 "2022-10-08T13:46:00Z")

</div>

Historically, whenever I have to do any formatting or math with dates and time, I’ve found it easiest to make the table in Google Sheets and do the calculations and conversions on the Google side of things. There are a lot more functions giving much more control over what Glide can do with dates and time natively. I haven’t tested Glide since the recent updates around time zones, but from what I’ve seen in this thread it looks like Glide still has room to grow.

---

<div class="post-metadata">

**Author:** ![Uzo](https://sea2.discourse-cdn.com/flex002/user_avatar/community.glideapps.com/uzo/32/22639_2.png) [@Uzo](https://community.glideapps.com/u/Uzo)\
**Post date:** [October 8, 2022, 1:49pm UTC](https://community.glideapps.com/t/how-to-convert-hhss-to-just-hh-mm/51152/27 "2022-10-08T13:49:35Z")

</div>

yep… you are absolutely right! but… it takes time to sync with GS and if you are using only Glide tables, a little bit of brain gymnastics will solve all problems 😉

---

<div class="post-metadata">

**Author:** ![Darren\_Murphy](https://sea2.discourse-cdn.com/flex002/user_avatar/community.glideapps.com/darren_murphy/32/47326_2.png) [@Darren\_Murphy](https://community.glideapps.com/u/Darren_Murphy)\
**Post date:** [October 8, 2022, 1:58pm UTC](https://community.glideapps.com/t/how-to-convert-hhss-to-just-hh-mm/51152/28 "2022-10-08T13:58:49Z")

</div>

> [@NFNHello](#):
>
> Historically, whenever I have to do any formatting or math with dates and time, I’ve found it easiest to make the table in Google Sheets and do the calculations and conversions on the Google side of things.

I’ll admit that it took me a very long time to get my head around working with dates and times in Glide, but now that I’m relatively comfortable with it I can’t possibly imagine a scenario where I’d ever try and do any sort of date/time manipulation or formatting in a Google Sheet.

But each to their own 🙂

---

<div class="post-metadata">

**Author:** ![Hassan\_Nadeem](https://sea2.discourse-cdn.com/flex002/user_avatar/community.glideapps.com/hassan_nadeem/32/72956_2.png) [@Hassan\_Nadeem](https://community.glideapps.com/u/Hassan_Nadeem)\
**Post date:** [October 8, 2022, 2:18pm UTC](https://community.glideapps.com/t/how-to-convert-hhss-to-just-hh-mm/51152/29 "2022-10-08T14:18:12Z")

</div>

That looks like exactly what I want. How’d you configure the “Convert Duration” Column?

---

<div class="post-metadata">

**Author:** ![Uzo](https://sea2.discourse-cdn.com/flex002/user_avatar/community.glideapps.com/uzo/32/22639_2.png) [@Uzo](https://community.glideapps.com/u/Uzo)\
**Post date:** [October 8, 2022, 2:19pm UTC](https://community.glideapps.com/t/how-to-convert-hhss-to-just-hh-mm/51152/30 "2022-10-08T14:19:38Z")

</div>

![Screen Shot 2022-10-08 at 9.58.39 AM](https://us1.discourse-cdn.com/flex002/uploads/glideapps/original/3X/2/5/252d8dcf2efc930b16282871bcc39d3dafd8a421.png)

just don’t use it for other calculations in the app… only for displaying

---

<div class="post-metadata">

**Author:** ![NFNHello](https://sea2.discourse-cdn.com/flex002/user_avatar/community.glideapps.com/nfnhello/32/3371_2.png) [@NFNHello](https://community.glideapps.com/u/NFNHello)\
**Post date:** [October 8, 2022, 3:24pm UTC](https://community.glideapps.com/t/how-to-convert-hhss-to-just-hh-mm/51152/31 "2022-10-08T15:24:19Z")

</div>

The big one that I haven’t taken the time to recreate the math within Glide is the “DATEDIF” function. The “YD”, “M” and “D” unit variables that do the leap year math for me is great. I’ve posted this elsewhere in more detail, but the summary is that while I COULD do the math and recreate in a Glide table, it is just easier to use the Google function.

---

<div class="post-metadata">

**Author:** ![Hassan\_Nadeem](https://sea2.discourse-cdn.com/flex002/user_avatar/community.glideapps.com/hassan_nadeem/32/72956_2.png) [@Hassan\_Nadeem](https://community.glideapps.com/u/Hassan_Nadeem)\
**Post date:** [October 8, 2022, 5:13pm UTC](https://community.glideapps.com/t/how-to-convert-hhss-to-just-hh-mm/51152/32 "2022-10-08T17:13:53Z")

</div>

I know this. Could you show the “CONVERT DURATION” settings?

---

<div class="post-metadata">

**Author:** ![Uzo](https://sea2.discourse-cdn.com/flex002/user_avatar/community.glideapps.com/uzo/32/22639_2.png) [@Uzo](https://community.glideapps.com/u/Uzo)\
**Post date:** [October 8, 2022, 5:27pm UTC](https://community.glideapps.com/t/how-to-convert-hhss-to-just-hh-mm/51152/33 "2022-10-08T17:27:25Z")

</div>

Just put that one… that’s all it is… `duration/60`

---

<div class="post-metadata">

**Author:** ![Uzo](https://sea2.discourse-cdn.com/flex002/user_avatar/community.glideapps.com/uzo/32/22639_2.png) [@Uzo](https://community.glideapps.com/u/Uzo)\
**Post date:** [October 9, 2022, 8:46am UTC](https://community.glideapps.com/t/how-to-convert-hhss-to-just-hh-mm/51152/34 "2022-10-09T08:46:06Z")

</div>

did you make it work?

---

<div class="post-metadata">

**Author:** ![Darren\_Murphy](https://sea2.discourse-cdn.com/flex002/user_avatar/community.glideapps.com/darren_murphy/32/47326_2.png) [@Darren\_Murphy](https://community.glideapps.com/u/Darren_Murphy)\
**Post date:** [October 9, 2022, 9:33am UTC](https://community.glideapps.com/t/how-to-convert-hhss-to-just-hh-mm/51152/35 "2022-10-09T09:33:11Z")

</div>

Well that’s interesting, and really really useful.

 ![Screen Shot 2022-10-09 at 5.26.56 PM](https://us1.discourse-cdn.com/flex002/uploads/glideapps/original/3X/1/9/1999a539893a37d019ef17d570a76d700f834a0b.png)

I’m not sure I can explain how or why that works - can you? 🤔

---

<div class="post-metadata">

**Author:** ![Uzo](https://sea2.discourse-cdn.com/flex002/user_avatar/community.glideapps.com/uzo/32/22639_2.png) [@Uzo](https://community.glideapps.com/u/Uzo)\
**Post date:** [October 9, 2022, 9:38am UTC](https://community.glideapps.com/t/how-to-convert-hhss-to-just-hh-mm/51152/36 "2022-10-09T09:38:44Z")

</div>

yes… is very simple, is like moving a decimal point in numbers, when you divide or multiply by 10 ;-)… so hours and minutes are counted to 60… when you divide by 60, it will move hours to minutes and minutes to seconds

---

<div class="post-metadata">

**Author:** ![Darren\_Murphy](https://sea2.discourse-cdn.com/flex002/user_avatar/community.glideapps.com/darren_murphy/32/47326_2.png) [@Darren\_Murphy](https://community.glideapps.com/u/Darren_Murphy)\
**Post date:** [October 9, 2022, 9:45am UTC](https://community.glideapps.com/t/how-to-convert-hhss-to-just-hh-mm/51152/37 "2022-10-09T09:45:54Z")

</div>

ah-ha!

I see what’s going on. So in actual fact, that’s not the true duration. We’ve just converted 32 hours and 30 minutes to 32 minutes and 32 seconds.

okay, so maybe not so useful after all. A little bit of smoke and mirrors

---

<div class="post-metadata">

**Author:** ![Uzo](https://sea2.discourse-cdn.com/flex002/user_avatar/community.glideapps.com/uzo/32/22639_2.png) [@Uzo](https://community.glideapps.com/u/Uzo)\
**Post date:** [October 9, 2022, 9:48am UTC](https://community.glideapps.com/t/how-to-convert-hhss-to-just-hh-mm/51152/38 "2022-10-09T09:48:02Z")

</div>

yes, that’s why I made a note for him, to use only for display purposes… so you can have two columns… one with a real duration for calculating… and one for displaying

---

<div class="post-metadata">

**Author:** ![Darren\_Murphy](https://sea2.discourse-cdn.com/flex002/user_avatar/community.glideapps.com/darren_murphy/32/47326_2.png) [@Darren\_Murphy](https://community.glideapps.com/u/Darren_Murphy)\
**Post date:** [October 9, 2022, 9:50am UTC](https://community.glideapps.com/t/how-to-convert-hhss-to-just-hh-mm/51152/39 "2022-10-09T09:50:07Z")

</div>

yeah, I get it.

It’s just converting `HH:MM:SS` to `MM:SS`, and the fact it “looks” like `HH:MM` is a useful side effect 🙂

---

<div class="post-metadata">

**Author:** ![Uzo](https://sea2.discourse-cdn.com/flex002/user_avatar/community.glideapps.com/uzo/32/22639_2.png) [@Uzo](https://community.glideapps.com/u/Uzo)\
**Post date:** [October 9, 2022, 9:50am UTC](https://community.glideapps.com/t/how-to-convert-hhss-to-just-hh-mm/51152/40 "2022-10-09T09:50:59Z")

</div>

yep, and it saves many columns to convert it in any other ways… plus you can still get correct calculations… and at the end, you can always multiply by 60 and get a real duration, if you wanna save one column lol

[Previous page](https://community.glideapps.com/t/how-to-convert-hhss-to-just-hh-mm/51152.md?page=1)

[Next page](https://community.glideapps.com/t/how-to-convert-hhss-to-just-hh-mm/51152.md?page=3)
