Duration values
Duration values are one of the types of Field values.
When you configure a field to have duration values, Dabble will only allow the field to contain a number and unit, and will warn you if a field does not contain a valid value.
Durations are used to measure a length of time when a specific date is not relevant. The values are numeric and measure time in days, hours and minutes.
Durations are similar to Number values in that they allow you to make mathematical calculations. The difference is that duration values are computed on a time basis (60 minutes in an hour, 24 hours in a day, 365 days in a year).
Please see Number values for more information on how numeric data is used in Dabble. You can use duration fields as you would any other numeric field — to create subtotals and Formulas, or to filter.
Converting a field to have duration values
You can change a field to have duration values using the Field configuration. When you do this, existing data in the field will be converted. Text that cannot be interpreted as a number or unit of measurement will be stripped out. If a field contains some text and Dabble cannot find a duration in it, it will warn the user that the field contains Invalid data. When you enter new data into a number field, the same behavior will apply.
Duration options
In the Field configuration there is one option you can change for duration value fields. You can specify a default duration for when entries are created with this field. This only applies to the future: existing entries will not have their values changed.
Entering duration values
The default unit for durations is minutes, but you can enter measurements in days, hours, minutes or any combination of them. If you type a number or import data with no unit, it will be interpreted in minutes. You can use shorthand when entering durations.
Examples of durations Dabble understands
Although Dabble understands all of these forms, duration values will be converted into a consistent format when saved or imported. The text on the left shows what might be typed while the text on the right shows what will be displayed.
| Data entered into Dabble | What Dabble displays |
|---|---|
| 5 | 0h05 |
| 5 hours | 5h |
| 5h | 5h |
| 5.5h | 5h30 |
| 5 hours 30 minutes | 5h30 |
| 30 minutes | 0h30 |
| 30m | 0h30 |
| 25 hours | 1 day, 1h |
| 4 days | 4 days |
| 4 days 5 hours 30 minutes | 4 days, 5h30 |
| 1 year | 365 days |
| 1 year, 5 days | 370 days |
