Share via

Nested IF statement with EDATE and TODAY()

Anonymous
2010-09-06T14:12:01+00:00

I currently have the following formula in column AV

=IF(AU2="D/D","",IF(AU2>EDATE(B2,5),"DELAY",""))

AU column contains either "D/D" or current estimated delivery date, B2 contains the order date. The above shows "DELAY" if an order has taken longer than 5 month and nothing if its already been delivered.

What I want to do is add to the above IF statement that also says "DELAY" if the the current status in column AR says "ORDER RECEIVED" and its status date in column AT is more than 3 months old from today's date. I think I need something like the following that works and not give me #value!

=IF(AR324="ORDER RECEIVED",IF(EDATE(AT324,3>TODAY()),"DELAY",""),IF(AU324="D/D","",IF(AU324>EDATE(B324,5),"DELAY","")))

Any help would be appreciated

Microsoft 365 and Office | Excel | For home | Windows

Locked Question. This question was migrated from the Microsoft Support Community. You can vote on whether it's helpful, but you can't add comments or replies or follow the question.

0 comments No comments

Answer accepted by question author

Anonymous
2010-09-07T15:43:19+00:00

Solved it with this

=IF(AU324="",IF(EDATE(AT324,3)<TODAY(),"LATE",""),IF(AU324="D/D","",IF(AU324>EDATE(B324,5),"DELAY","")))

Thanks for everyone's help in pointing me in the right direction

Was this answer helpful?

1 person found this answer helpful.
0 comments No comments

14 additional answers

Sort by: Most helpful
  1. Anonymous
    2010-09-06T16:05:44+00:00

    Sorry for not putting it across that clearly - brain's riddled with IF possibilities!

    Original formula =IF(AU325="D/D","",IF(AU325>EDATE(B325,5),"DELAY","")) works fine

    I've worked out the 2nd bit as a seperate formula =IF(AU324="",IF(EDATE(AT324,3)<TODAY(),"LATE",""),"") which works

    Now I just need to combine the 2 formula's into 1 nested IF statement.

    Was this answer helpful?

    0 comments No comments
  2. Anonymous
    2010-09-06T15:41:28+00:00

    Sorry, should have mentioned that if a status is still at "Order Received" then no date has been entered in the column AU, hence why I need to work with the date in column AT

    Well, I'm not following you on this but, based on the above statement then that would mean:

    ...IF(OR(AU324>EDATE(B324,5),...

    Would always be TRUE thus returning the "Delay" result provided that AU324 does not contain "D/D".

    So, we need to make sure AU isn't empty.

    Maybe this:

    =IF(AU324="D/D","",IF(OR(AND(AU324<>"",AU324>EDATE(B324,5)),AND(AR324="ORDER RECEIVED",EDATE(AT324,3)>TODAY())),"DELAY",""))

    --

    Biff

    Microsoft Excel MVP

    Was this answer helpful?

    0 comments No comments
  3. Anonymous
    2010-09-06T14:46:22+00:00

    Sorry, should have mentioned that if a status is still at "Order Received" then no date has been entered in the column AU, hence why I need to work with the date in column AT

    Was this answer helpful?

    0 comments No comments
  4. Anonymous
    2010-09-06T14:26:36+00:00

    I currently have the following formula in column AV

    =IF(AU2="D/D","",IF(AU2>EDATE(B2,5),"DELAY",""))

    AU column contains either "D/D" or current estimated delivery date, B2 contains the order date. The above shows "DELAY" if an order has taken longer than 5 month and nothing if its already been delivered.

    What I want to do is add to the above IF statement that also says "DELAY" if the the current status in column AR says "ORDER RECEIVED" and its status date in column AT is more than 3 months old from today's date. I think I need something like the following that works and not give me #value!

    =IF(AR324="ORDER RECEIVED",IF(EDATE(AT324,3>TODAY()),"DELAY",""),IF(AU324="D/D","",IF(AU324>EDATE(B324,5),"DELAY","")))

    Any help would be appreciated

    Try it like this...

    =IF(AU324="D/D","",IF(OR(AU324>EDATE(B324,5),AND(AR324="ORDER RECEIVED",EDATE(AT324,3)>TODAY())),"DELAY",""))

    --

    Biff

    Microsoft Excel MVP

    Was this answer helpful?

    0 comments No comments