Skip to main content

IF Between two dates - total of column

  • March 9, 2020
  • 4 replies
  • 35 views

Hi Team

Trying to get a formula going to show me a total for ‘stock on order quantity’ if its in-between two dates.

Using the below, but getting a blank answer rather than what is in the ‘quantity’ column

Can someone help see what my mistake is?

IF(AND(IS_AFTER({Order Date},TODAY()),IS_BEFORE({Arrive By},TODAY())),Quantity,BLANK())

Thanks

4 replies

kuovonne
Forum|alt.badge.img+29
  • Brainy
  • March 9, 2020

Your formula looks good to me.

Have you checked the data to make sure that there are records that actually fit the conditions? Also make sure that there are no timezone issues that can shift dates around slightly.

Keep in mind that the formula won’t include any stock that was ordered TODAY().


  • Author
  • New Participant
  • March 9, 2020

Your formula looks good to me.

Have you checked the data to make sure that there are records that actually fit the conditions? Also make sure that there are no timezone issues that can shift dates around slightly.

Keep in mind that the formula won’t include any stock that was ordered TODAY().


Yup - played around with the dates to make sure they are wide and still not showing anything.


kuovonne
Forum|alt.badge.img+29
  • Brainy
  • March 9, 2020

D’oh. Switch your IS_BEFORE and IS_AFTER.

You want the {Order Date} to be before today, and the {Arrive By} to be after today. You have it the other way around.

I usually use DATETIME_DIFF (do take into account things like including the current date), and I didn’t remember the exact syntax of the two formulas you used off the top of my head.


  • Author
  • New Participant
  • March 9, 2020

D’oh. Switch your IS_BEFORE and IS_AFTER.

You want the {Order Date} to be before today, and the {Arrive By} to be after today. You have it the other way around.

I usually use DATETIME_DIFF (do take into account things like including the current date), and I didn’t remember the exact syntax of the two formulas you used off the top of my head.


DOH!!! thanks - that did it.

So close yet so far away from being intelligent…