+ Reply to Thread
Results 1 to 3 of 3

Excel 2007 : IF Formula based on two criteria

Hybrid View

  1. #1
    Registered User
    Join Date
    01-12-2012
    Location
    Hong Kong
    MS-Off Ver
    Excel 2007
    Posts
    2

    Red face IF Formula based on two criteria

    Hi guys,

    I have a table that looks like the following:

    Status Age
    Local 2
    Expat 3
    LOCAL 4
    expat 5
    Local 6

    The logical tests should be, if age=2 then NO, if age=3 or 4 then .75, if age = 5 of above then 1. However, all the previous is only applicable if the person is an Expat. I.e. if they are local, then no matter what age it should return NO.

    I've put in this formula but it says I have too many arguments:

    =IF(N22<3,"NO",IF(AND(N22=3,J22="expat"),0.75,"NO",IF(AND(N22=4,J22="expat"),0.75,"NO",IF(AND(N22=5,J22="expat"),1,"NO",IF(AND(N22>5,J22="expat"),1,"NO")))))

    I can't get it to work... any help would be greatly appreciated!

  2. #2
    Forum Guru
    Join Date
    03-02-2006
    Location
    Los Angeles, Ca
    MS-Off Ver
    WinXP/MSO2007;Win10/MSO2016
    Posts
    12,946

    Re: IF Formula based on two criteria

    =IF(J22="Expat",IF(N22<3,"No",IF(N22>4,1,0.75)),"")
    Ben Van Johnson

  3. #3
    Registered User
    Join Date
    01-12-2012
    Location
    Hong Kong
    MS-Off Ver
    Excel 2007
    Posts
    2

    Re: IF Formula based on two criteria

    Thank you soooo much! I understand now, it can be simplified. Thanks again!

+ Reply to Thread

Thread Information

Users Browsing this Thread

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

Tags for this Thread

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