Skip to main content
Question

Multiple IFs statements

  • October 7, 2025
  • 6 replies
  • 51 views

Forum|alt.badge.img+2

I have this formula that is working: IF({Start date},DATETIME_FORMAT(DATEADD({Start date},14, 'days'),'MM/DD/YYYY'),"") 

I want to incorporate these conditions to it:

IF(Category = "Playbooks",14, 'days')

IF(Category = "How-to-Guides",3,’days')

 

 

6 replies

Mike_AutomaticN
Forum|alt.badge.img+28

Hey ​@Leyvis,

You might want to give the following formula a shot:
 

IF(
{Start date},
DATETIME_FORMAT(
DATEADD(
{Start date},
IF(
{Category} = "Playbooks",
14,
IF(
{Category} = "How-to-Guides",
3,
0
)
),
'days'
),
'MM/DD/YYYY'
),
""
)

 
Completely different matter, but would love to have you join our Airtable Hackathon! Make sure to sign up!!

Mike, Consultant @ Automatic Nation 
YouTube Channel 


DisraeliGears01
Forum|alt.badge.img+21

I used SWITCH instead of nested IFs because it makes a bit more sense to me, but this should work…

IF({Start date}, 
SWITCH(
{Category},
"Playbooks",DATETIME_FORMAT(DATEADD({Start date},14, 'days'),'MM/DD/YYYY'),
"How-To-Guides", DATETIME_FORMAT(DATEADD({Start date},3, 'days'),'MM/DD/YYYY')), "")

You can also add more categories pretty simply this way.


Mike_AutomaticN
Forum|alt.badge.img+28

Yes, ​@DisraeliGears01 solution is way cleaner :D

Mike, Consultant @ Automatic Nation 
YouTube Channel


Forum|alt.badge.img+2
  • Author
  • New Participant
  • October 8, 2025

Hey ​@Leyvis,

You might want to give the following formula a shot:
 

IF(
{Start date},
DATETIME_FORMAT(
DATEADD(
{Start date},
IF(
{Category} = "Playbooks",
14,
IF(
{Category} = "How-to-Guides",
3,
0
)
),
'days'
),
'MM/DD/YYYY'
),
""
)

 
Completely different matter, but would love to have you join our Airtable Hackathon! Make sure to sign up!!

Mike, Consultant @ Automatic Nation 
YouTube Channel 

Right on, it clarified how to include the additional If statements. Thank you. 


Forum|alt.badge.img+2
  • Author
  • New Participant
  • October 8, 2025

I used SWITCH instead of nested IFs because it makes a bit more sense to me, but this should work…

IF({Start date}, 
SWITCH(
{Category},
"Playbooks",DATETIME_FORMAT(DATEADD({Start date},14, 'days'),'MM/DD/YYYY'),
"How-To-Guides", DATETIME_FORMAT(DATEADD({Start date},3, 'days'),'MM/DD/YYYY')), "")

You can also add more categories pretty simply this way.

So much cleaner approach and less thinking of all the parenthesis and commas. I will start playing with SWITCH.


TheTimeSavingCo
Forum|alt.badge.img+31

A further addition!

IF(
{Start Date},
DATETIME_FORMAT(
DATEADD(
{Start Date},
SWITCH(
{Category},
'Playbooks', 14,
'How-To-Guides', 3
),
'days'
),
'MM/DD/YYYY'
)
)