Skip to main content

DateAdd Function

  • February 10, 2025
  • 4 replies
  • 27 views

Forum|alt.badge.img+3

Hello,  

I am trying to create a formula to put together a date we expect something to be completed.

Date to Client is entered by my team and is the first part of the equation.

Client Timing is pulled as a lookup field from another table dependent on each client as is based in days.  

Formula I have is 

Dateadd({Date to Client}, {Client Timing}, "days").  This equation is taking the client date (ex 12/2/25) and always subtracting one (ex 12/1/25.

Is there a different formula I should be using for this type of transaction?

4 replies

Mike_AutomaticN
Forum|alt.badge.img+28

Hey @Zak1,

What is the issue with your current formula? Is it not working?
If so, you might want to try using a rollup rather than a lookup for Client Timing just in case. For the formula you might want to use Arrayjoin, Sum, or Max depending on your use case.

Lookups might be treated as Arrays by Airtable. 


Forum|alt.badge.img+3
  • Author
  • New Participant
  • February 10, 2025

Hey @Zak1,

What is the issue with your current formula? Is it not working?
If so, you might want to try using a rollup rather than a lookup for Client Timing just in case. For the formula you might want to use Arrayjoin, Sum, or Max depending on your use case.

Lookups might be treated as Arrays by Airtable. 


The formula is always just subtracting one from the current date and not using the number in the lookup (ex. 10).  I will try a rollup to see if that may work.  Thanks.

 


TheTimeSavingCo
Forum|alt.badge.img+31

Does this look right? 

 

DATEADD( {Date to Client}, {Client timing (from Clients)} + 0, 'days' )

 

 


Alexey_Gusev
Forum|alt.badge.img+25
  • Brainy
  • February 12, 2025

To summarize the solution from @TheTimeSavingCo , lookup is Array
sometimes you can use it it formulas as is, but sometimes you need to use
{Lookup} + 0  to convert Array to Number
{Lookup} & ''  to convert Array to String

alternatively, you can change it to Rollup with array function,
SUM(values) for Numbers
ARRAYJOIN(values)  or ARRAYUNIQUE(values) for Strings