Skip to main content

I’m looking for help to write a formula that will help filter records that meet these requirements. I can’t seem to get it done using the filter function.



Where date is within the next week


or


Where date is within the last 3 days


and


Where check box is not marked

Hi and welcome to Airtable!





Do you mean literaly within the next week, like within week 39 now, or do you mean within the next 7 days?


Try this:



IF( 

OR(

DATETIME_FORMAT(Date, 'W') = DATETIME_FORMAT( DATEADD(Today(), 1, 'weeks') , 'W'),

And(

IS_BEFORE(Date, Today()),

IS_AFTER(Date, DATEADD(Today(), -4, 'days')),

Checkbox = 1

)

),

"Meets criteria",

"Don't meet criteria"

)


Try this:



IF( 

OR(

DATETIME_FORMAT(Date, 'W') = DATETIME_FORMAT( DATEADD(Today(), 1, 'weeks') , 'W'),

And(

IS_BEFORE(Date, Today()),

IS_AFTER(Date, DATEADD(Today(), -4, 'days')),

Checkbox = 1

)

),

"Meets criteria",

"Don't meet criteria"

)


Thank you so much - I actually figured out a way to force it to work by reordering the filters!


Reply