Help

Re: How to skip rows if they have values

365 0
cancel
Showing results for 
Search instead for 
Did you mean: 
Sav_Aylett
4 - Data Explorer
4 - Data Explorer

Hey all completely new to Airtables, merely hours in! I was wondering how do I move on to the next cell if the current cell has a value? I’m trying to calculate deadlines given an estimated number of days a project will take from a production date, however occassionally I’ll have a predetermined deadline but no start date so want the value to remain and move onto the next row. My formula is:

IF({Build Start}, DATEADD({Build Start}, {Build Days}, ‘days’))

This works but if a value already exists it replaces it with a blank space? Ideally I’d just use an else and continue.

2 Replies 2

Welcome to the community, @Sav_Aylett! :grinning_face_with_big_eyes: Airtable formulas always execute on all records, meaning that they always generate some output, even if that output is nothing (blank). They also can’t look at the output from a previous execution of the same formula and use that as input for the current execution (your “if a value already exists” idea). If part of a formula’s input changes—e.g. a value in a specific field used by the formula—the formula will re-run for that record.

One way to do what you’re seeking is to include a manual date field where you can input a deadline—I’ll call it the {Build End Manual} field—and then use the contents of that field in your formula logic. Maybe something like this:

IF(
  {Build Start},
  IF(
    {Build End Manual},
    {Build End Manual},
    DATEADD({Build Start}, {Build Days}, 'days'),
  ),
  IF(
    {Build End Manual},
    {Build End Manual}
  )
)

The logic is this: if there’s a specified start date, use that to calculate the end date, but only if there’s no manual end date entered; otherwise use the manual end date. If there’s no start date, use the manual end date if it exists.

Cheers Justin, I shall give it a go and get back to you. Again many thanks for the pointer.