Skip to main content
Solved

Formula to define No of months ahead


Hi Everyone,

I was wondering if I can create a formula that gives me a certain number of months ahead instead of changing the filter from a certain date to date each month, sometimes we miss it, so I want to set up the filter to read from the formula

I want the formula to read from my ( Release Date ), this exiting month and 2 months ahead
like give me Feb, March, and April as true, so when I tell the filter to give only what is “true,” it will give me those 3 months, and it will automatically drop one and add another each beginning of a new month.

Thanks a lot
Ahmed Elagami

Best answer by Kamille_Parks11

There’s a good chance I misunderstood what it is you’re asking for, but the following formula will return “true” for all records where a given date is somewhere between the 1st of the current month (February 1) and the last day of two months forward (April 31):

IF(
   {Release Date}, 
   IF(
      AND(
         {Release Date} < DATEADD(DATEADD(DATETIME_FORMAT(TODAY(), 'YYYY/MM/01'), 3, 'months'), -1, 'day'), 
         {Release Date} >= DATETIME_PARSE(DATETIME_FORMAT(TODAY(), 'YYYY/MM/01'))
      ), 
      "true", 
      "false"
   )
)
View original
Did this topic help you find an answer to your question?

2 replies

Kamille_Parks11
Forum|alt.badge.img+15

There’s a good chance I misunderstood what it is you’re asking for, but the following formula will return “true” for all records where a given date is somewhere between the 1st of the current month (February 1) and the last day of two months forward (April 31):

IF(
   {Release Date}, 
   IF(
      AND(
         {Release Date} < DATEADD(DATEADD(DATETIME_FORMAT(TODAY(), 'YYYY/MM/01'), 3, 'months'), -1, 'day'), 
         {Release Date} >= DATETIME_PARSE(DATETIME_FORMAT(TODAY(), 'YYYY/MM/01'))
      ), 
      "true", 
      "false"
   )
)

  • Author
  • Known Participant
  • 27 replies
  • February 10, 2021

@Kamille_Parks Thanks for your help, that worked exactly the way I wanted, Appreciate your help Kamille.

My Best
Ahmed Elagami


Reply