+ Reply to Thread
Results 1 to 10 of 10

IF function with dates and conditions

  1. #1
    Registered User
    Join Date
    09-12-2012
    Location
    Whiting, Indiana
    MS-Off Ver
    Excel 2010
    Posts
    2

    IF function with dates and conditions

    Hello, my manager gave me a project today with 10,000 rows of data due tomorrow. I'm not familiar enough with Excel to write the below IF function. I would prefer not to do this manually. Can I please get some assistance. Basically, I need to choose the oldest date and set conditions. This is my first time on the forum. Please see attachment.



    if A2=C2, N
    if C3 is "empty" choose W
    if A6 is "empty" choose L
    if C7 is "updating" choose W
    if C4 is < A4 choose L
    if A5 is < C5 choose W
    Attached Files Attached Files

  2. #2
    Forum Moderator vlady's Avatar
    Join Date
    09-22-2011
    Location
    Philippines - OLSHCO -Guimba-Nueva Ecija
    MS-Off Ver
    2021
    Posts
    4,361

    Re: IF function with dates and conditions

    maybe this
    in cell F2

    Formula: copy to clipboard
    Please Login or Register  to view this content.


    ooppsss i missed one if sorry
    corrected:

    Please Login or Register  to view this content.
    Last edited by vlady; 09-12-2012 at 09:21 PM.
    I think people forget the word "THANK YOU!!!!" Do you still know it???

    There is a little star ( ADD REPUTATION ) below those person who helped you. Click it to say your "PRIVATE APPRECIATION TO THEIR EFFORT ON THEIR CONTRIBUTIONS "

    Regards,
    Vladimir

  3. #3
    Forum Guru MarvinP's Avatar
    Join Date
    07-23-2010
    Location
    Woodinville, WA
    MS-Off Ver
    Office 365
    Posts
    16,168

    Re: IF function with dates and conditions

    Hi Mary24 and welcome to the forum.

    I'm not sure your last condition is correct but look at the attached to see if it works for you.
    Attached Files Attached Files
    Last edited by MarvinP; 09-12-2012 at 10:17 PM.
    One test is worth a thousand opinions.
    Click the * Add Reputation below to say thanks.

  4. #4
    Forum Guru MarvinP's Avatar
    Join Date
    07-23-2010
    Location
    Woodinville, WA
    MS-Off Ver
    Office 365
    Posts
    16,168

    Re: IF function with dates and conditions

    Hey vlady,

    I hate wrong answers. What if a BLANK is less than anything? That would make your formula in Row 3 wrong. Did you check your answer before you gave it?

    I stand by my signature line of: One test is worth a thousand opinions.

  5. #5
    Forum Moderator vlady's Avatar
    Join Date
    09-22-2011
    Location
    Philippines - OLSHCO -Guimba-Nueva Ecija
    MS-Off Ver
    2021
    Posts
    4,361

    Re: IF function with dates and conditions

    sorry i have edited it time 9:21 before you posted #4

    @marry
    another option if both are blank

    =IF(AND(A2="",C2=""),"",IF(A2=C2,"N",IF(C2="","W",IF(OR(A2="",C2<A2),"L",IF(OR(C2="Updating",A2<C2),"W","")))))

    i hate also wrong answer,
    how can you attain "No match" what example will be applicable for that.
    Last edited by vlady; 09-12-2012 at 09:47 PM.

  6. #6
    Forum Guru MarvinP's Avatar
    Join Date
    07-23-2010
    Location
    Woodinville, WA
    MS-Off Ver
    Office 365
    Posts
    16,168

    Re: IF function with dates and conditions

    @ Vlladdddyyyy - her name is Mary, not marry as you typed above.

    Sorry for finding your errors!!

    You can attain "No match" by carefully trying all possible combinations of data in the A and C columns. If you can't get that as a result, then there is a "No match". I'll let you work on it.

  7. #7
    Forum Moderator vlady's Avatar
    Join Date
    09-22-2011
    Location
    Philippines - OLSHCO -Guimba-Nueva Ecija
    MS-Off Ver
    2021
    Posts
    4,361

    Re: IF function with dates and conditions

    i found it not you...that's why i edited my post... then u posted #4
    look at the time of postings.

    edited is 9:21
    post#4 is 9:24

    thanks.

  8. #8
    Forum Guru MarvinP's Avatar
    Join Date
    07-23-2010
    Location
    Woodinville, WA
    MS-Off Ver
    Office 365
    Posts
    16,168

    Re: IF function with dates and conditions

    Mary <> marry <> Marvin either - see post #5.

    Sorry for the corrections - I need a beer and some sleep.

    I wonder if Mary will come back and see some of the possible answers for her problem?

  9. #9
    Forum Moderator vlady's Avatar
    Join Date
    09-22-2011
    Location
    Philippines - OLSHCO -Guimba-Nueva Ecija
    MS-Off Ver
    2021
    Posts
    4,361

    Re: IF function with dates and conditions

    i think mary is online.
    sorry marvin,
    i think i need also a beer or two.
    i think i better to log-out for now.

    regards,
    vladimir

  10. #10
    Registered User
    Join Date
    09-12-2012
    Location
    Whiting, Indiana
    MS-Off Ver
    Excel 2010
    Posts
    2

    Re: IF function with dates and conditions

    THANK YOU!!!!! The last formula worked perfect. Thank you for writing in the formula both blanks since I forgot to mention it to you. I tested the formula against 200 rows that I manually did and it's a perfect match. I'm so happy. Tremendous!

    =IF(AND(A2="",C2=""),"",IF(A2=C2,"N",IF(C2="","W",IF(OR(A2="",C2<A2),"L",IF(OR(C2="Updating",A2<C2),"W","")))))

+ Reply to Thread

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts

Search Engine Friendly URLs by vBSEO 3.6.0 RC 1