Skip to main content
Solved

Using DATEADD doesn't aggregate the data

  • February 23, 2020
  • 2 replies
  • 23 views

Forum|alt.badge.img+6

Hi airtablers

I’m trying to create a business schedule table.
There are ‘start time’ and ‘duration’(a lookup value from a different base) fields, and I try to formulate the ‘end time’ field by aggregating the first 2.

For some reason the below formula gives the start time unchanged.

DATEADD({Start time},Duration,'seconds')

I tried to change the seconds to minutes and hours with same result. {Duration} also didn’t change.

The formatting option “Use the same time zone (GMT) for all collaborators”, is disabled in both date fields.

What am I doing wrong?

Thanks

Best answer by kuovonne

I was able to see the same problem as you. I suspect the problem has to do with the lookup.

My workaround was to force the {duration} into a number by adding zero to it.

DATEADD({Start time}, {Duration} + 0, 'second')

In my test, only {Duration} is a lookup; {Start time} is a regular date/time field.

2 replies

kuovonne
Forum|alt.badge.img+29
  • Brainy
  • Answer
  • February 23, 2020

I was able to see the same problem as you. I suspect the problem has to do with the lookup.

My workaround was to force the {duration} into a number by adding zero to it.

DATEADD({Start time}, {Duration} + 0, 'second')

In my test, only {Duration} is a lookup; {Start time} is a regular date/time field.


Forum|alt.badge.img+6
  • Author
  • Participating Frequently
  • February 24, 2020

I was able to see the same problem as you. I suspect the problem has to do with the lookup.

My workaround was to force the {duration} into a number by adding zero to it.

DATEADD({Start time}, {Duration} + 0, 'second')

In my test, only {Duration} is a lookup; {Start time} is a regular date/time field.


Thank you so much :slightly_smiling_face: