# Formula to set a duration (DateTimeRange)

**URL:** <https://community.fibery.io/t/formula-to-set-a-duration-datetimerange/2384>\
**Category:** Get Help\
**Created:** [January 13, 2022, 6:26pm UTC](https://community.fibery.io/t/formula-to-set-a-duration-datetimerange/2384 "2022-01-13T18:26:31Z")\
**Posts on this page:** 1\
**Showing post:** 4

<div class="post-metadata">

**Author:** ![Chr1sG](https://sea2.discourse-cdn.com/flex020/user_avatar/community.fibery.io/chr1sg/32/3941_2.png) [@Chr1sG](https://community.fibery.io/u/Chr1sG)\
**Post date:** [January 19, 2022, 2:36pm UTC](https://community.fibery.io/t/formula-to-set-a-duration-datetimerange/2384/4 "2022-01-19T14:36:00Z")

</div>

It’s a fair point, and you’re not the first to recognise a need:

> [@Variables in formulas](https://community.fibery.io/t/variables-in-formulas/1277):
>
> Hi, I have been writing some quite advanced formulas in Fibery: I found that after some time even I cannot figure out what the heck formula does as it’s all in one gigantic expression. Would it be possible to add support for variables so that formulas can stay readable overtime? My only workaround now is to create a bunch of other formula fields and use them instead. However, that creates a lot of unnecessary noise in the type structure.

---

_[View the full topic](https://community.fibery.io/t/formula-to-set-a-duration-datetimerange/2384)._
