Hi there, Im new to airtable and Im having difficulty with formulas in general.
Currently on my table is Name, Date and the Promo
What Im trying to achieve is that every time a new person and the date is added, the person is given a promo based on the date provided
For example
John Doe - Jan 1 2021 - promo 1 (during 1 week of the date)
John Doe - Jan 1 2021 - promo 2 (after 1 week but during 2 weeks of the date)
John Doe - Jan 1 2021 - promo 3 (after 2 weeks but during 3 weeks of the date)
I know this may be difficult which is why Im asking the community for assistance on this part.
Thank you!
If statement with date formula
Best answer by TheTimeSavingCo
Hi! Thank you for replying.
So, every new person (and date) that is added in Airtable is basically a customer who availed our products. The idea is that they have 1 week to avail our promo 1, and 2 weeks to avail our promo 2 and 3 weeks for promo 3 and lastly 4 weeks/1 month for our promo 4.
So, for example (from the pic) as soon as John Doe and the date he availed our product is added, he has a 7days/1 week to avail our promo 1 which makes "Current Promo" field as Promo 1. After a week, the field would now be as Promo 2 and after that week its Promo 3 and so on.
So far I've only made:
to show when the promo ends but that's not exactly what I'm hoping to achieve exactly as I'm trying to see what Current Promo John is on without having to check calendars and dates to confirm the duration of said promo. I know my request may seem difficult and I apologize for requiring a very specific solution.
Ahh I see, is this sort of what you're looking for?

If so, here's a link to the base
And the script used is:
SWITCH(
DATETIME_DIFF(
TODAY(),
Date,
'weeks'
),
0, 'Promo 1',
1, 'Promo 2',
2, 'Promo 3'
)The idea is to find out how many weeks it's been since the "Date" value, and based on that we'll know which promo they're on, does that make sense?
Login to the community
Enter your E-mail address. We'll send you an e-mail with instructions to reset your password.
