Skip to content
View in the app

A better way to browse. Learn more.

FMForums.com

A full-screen app on your home screen with push notifications, badges and more.

To install this app on iOS and iPadOS
  1. Tap the Share icon in Safari
  2. Scroll the menu and tap Add to Home Screen.
  3. Tap Add in the top-right corner.
To install this app on Android
  1. Tap the 3-dot menu (⋮) in the top-right corner of the browser.
  2. Tap Add to Home screen or Install app.
  3. Confirm by tapping Install.

Time Field for Durations?

Featured Replies

I need to create a 'Duration' field for a Table of movies to enter the Hours / Mins / Seconds.   The 'Time' Field type seems to be designed for time of day, not a length of time, and it seems like it could be used for my purposes here, since no film would be longer than 24 hours.  Since the Time field is stored a numerical value of seconds, it would seem to 'behave' as I'd want it too, and I could use calculations to render the time in minutes or hours and minutes as needed.

But is this a 'best practice'?  Am I overlooking some potential unintended and unwanted consequences using a Time Field for Duration as opposed to time of day?   Something that will come back to haunt me?  if so, what is the alternative -- creating 3 fields for Hr/Min/Sec and manipulating them as needed?

 

32 minutes ago, Wickerman said:

The 'Time' Field type seems to be designed for time of day,

No, it is perfectly suitable for durations as well.

33 minutes ago, Wickerman said:

it seems like it could be used for my purposes here, since no film would be longer than 24 hours.

There's no problem with using a Time field for storing durations that exceed 24 hours either.

34 minutes ago, Wickerman said:

But is this a 'best practice'?

That depends on your situation, but in general I would say yes. But keep in mind that entering times is not as straightforward as entering dates, for example.

 

  • Author

Thanks very much for the reassurance. Feel I can go forward confidently here.

Create an account or sign in to comment

Important Information

By using this site, you agree to our Terms of Use.

Account

Navigation

Search

Search

Configure browser push notifications

Chrome (Android)
  1. Tap the lock icon next to the address bar.
  2. Tap Permissions → Notifications.
  3. Adjust your preference.
Chrome (Desktop)
  1. Click the padlock icon in the address bar.
  2. Select Site settings.
  3. Find Notifications and adjust your preference.