# Optional Duration Field Causes Error When Left Empty

**URL:** https://community.baserow.io/t/optional-duration-field-causes-error-when-left-empty/12501
**Category:** Uncategorized
**Tags:** data
**Created:** [June 9, 2026, 7:11am UTC](https://community.baserow.io/t/optional-duration-field-causes-error-when-left-empty/12501 "2026-06-09T07:11:09Z")
**Posts on this page:** 7
**Page:** 1

<div class="post-metadata">

### Author: ![Luc13](https://community.baserow.io/letter_avatar_proxy/v4/letter/l/47e85d/32.png) [@Luc13](https://community.baserow.io/u/Luc13)
#### Post date: [June 9, 2026, 7:11am UTC](https://community.baserow.io/t/optional-duration-field-causes-error-when-left-empty/12501/1 "2026-06-09T07:11:09Z")

</div>

Hello,

I’m experiencing an issue with a **Duration** field in Baserow.

In my application form, this field is optional and may sometimes be left empty by the user. However, when no value is provided, it seems to generate an error instead of being accepted.

What I would like is for an empty Duration field to automatically be interpreted as **0d** (zero days), or at least to be accepted without causing a validation error.

Is there a recommended way to configure a Duration field so that empty values default to **0d**? Alternatively, is there a best practice for handling optional Duration fields in forms?

I already tried : _if( is\_empty( Data\_Duration) , “0d” , Data\_Duration)_

But it wasn’t successfull…

Thank you for your help.

---

<div class="post-metadata">

### Author: ![olgatrykush](https://community.baserow.io/user_avatar/community.baserow.io/olgatrykush/32/219_2.png) [@olgatrykush](https://community.baserow.io/u/olgatrykush)
#### Post date: [June 10, 2026, 9:44am UTC](https://community.baserow.io/t/optional-duration-field-causes-error-when-left-empty/12501/2 "2026-06-10T09:44:04Z")

</div>

Hey @Luc13, what is the error you’re seeing?

---

<div class="post-metadata">

### Author: ![Luc13](https://community.baserow.io/letter_avatar_proxy/v4/letter/l/47e85d/32.png) [@Luc13](https://community.baserow.io/u/Luc13)
#### Post date: [June 10, 2026, 12:58pm UTC](https://community.baserow.io/t/optional-duration-field-causes-error-when-left-empty/12501/3 "2026-06-10T12:58:38Z")

</div>

“Value error for field “Duration”: The value is not a valid duration”

---

<div class="post-metadata">

### Author: ![olgatrykush](https://community.baserow.io/user_avatar/community.baserow.io/olgatrykush/32/219_2.png) [@olgatrykush](https://community.baserow.io/u/olgatrykush)
#### Post date: [June 12, 2026, 9:55am UTC](https://community.baserow.io/t/optional-duration-field-causes-error-when-left-empty/12501/4 "2026-06-12T09:55:27Z")

</div>

Hey @Luc13, are you using the SaaS version or self-hosting Baserow?

And is this happening in the Application Builder or in a Form view within the Database Builder?

---

<div class="post-metadata">

### Author: ![Luc13](https://community.baserow.io/letter_avatar_proxy/v4/letter/l/47e85d/32.png) [@Luc13](https://community.baserow.io/u/Luc13)
#### Post date: [June 12, 2026, 10:09am UTC](https://community.baserow.io/t/optional-duration-field-causes-error-when-left-empty/12501/5 "2026-06-12T10:09:22Z")

</div>

Saas Version and from the App builder.

---

<div class="post-metadata">

### Author: ![picklepete](https://community.baserow.io/user_avatar/community.baserow.io/picklepete/32/5332_2.png) [@picklepete](https://community.baserow.io/u/picklepete)
#### Post date: [June 12, 2026, 1:03pm UTC](https://community.baserow.io/t/optional-duration-field-causes-error-when-left-empty/12501/6 "2026-06-12T13:03:18Z")

</div>

Hi @Luc13 ,

> [@Luc13](#):
>
> What I would like is for an empty Duration field to automatically be interpreted as **0d** (zero days), or at least to be accepted without causing a validation error.

Could you use the “value” field? It represents the “default” / “initial” value. If you set it to `0d`, then if the value is left blank, we’ll default to that.

Cheers,

Peter

---

<div class="post-metadata">

### Author: ![Luc13](https://community.baserow.io/letter_avatar_proxy/v4/letter/l/47e85d/32.png) [@Luc13](https://community.baserow.io/u/Luc13)
#### Post date: [June 14, 2026, 5:59am UTC](https://community.baserow.io/t/optional-duration-field-causes-error-when-left-empty/12501/7 "2026-06-14T05:59:24Z")

</div>

Hi Peter,

I already tried the field value with 0d / “0d” / '0d / 0 , nothing works. It really look like a bug…

Any other idea ?

Thank’s  
Lucas
