+ Reply to Thread
Results 1 to 4 of 4

Nested If's/VLOOKUP's

  1. #1
    Registered User
    Join Date
    02-28-2007
    Posts
    29

    Nested If's/VLOOKUP's

    I am trying to write a formula that will tell me if a value in one cell appears in any of four lists in columns F, H, J, and L. I want it to return "FALSE" if it doesn't match any value in the 4 lists and "Match" if it does. I came up with this:

    =IF(ISNA(VLOOKUP(C4,F$4:F$1003,1,FALSE)),IF(ISNA(VLOOKUP(C4,H$4:H$1003,1,FALSE)),IF(ISNA(VLOOKUP(C4,J$4:J$1003,1,FALSE)),IF(ISNA(VLOOKUP(C4,L$4:L$1003,1,FALSE)),FALSE,"Match"))))

    But it's not returning the expected result. What am I doing wrong?

    Thanks in advance for the help
    JP
    Last edited by jpgoeth; 01-18-2008 at 02:53 PM. Reason: spelling fix

  2. #2
    Forum Expert NBVC's Avatar
    Join Date
    12-06-2006
    Location
    Mississauga, CANADA
    MS-Off Ver
    2003:2010
    Posts
    34,898
    Try using AND() to group your tests.:

    Please Login or Register  to view this content.
    you can also use Match instead of Vlookup when looking at single column arrrays....

    Please Login or Register  to view this content.
    Where there is a will there are many ways.

    If you are happy with the results, please add to the contributor's reputation by clicking the reputation icon (star icon) below left corner

    Please also mark the thread as Solved once it is solved. Check the FAQ's to see how.

  3. #3
    Registered User
    Join Date
    02-28-2007
    Posts
    29
    Both of those work - thanks a lot!

  4. #4
    Banned User!
    Join Date
    10-14-2006
    Posts
    1,211
    Quote Originally Posted by jpgoeth
    I am trying to write a formula that will tell me if a value in one cell appears in any of four lists in columns F, H, J, and L. I want it to return "FALSE" if it doesn't match any value in the 4 lists and "Match" if it does. I came up with this:

    =IF(ISNA(VLOOKUP(C4,F$4:F$1003,1,FALSE)),IF(ISNA(VLOOKUP(C4,H$4:H$1003,1,FALSE)),IF(ISNA(VLOOKUP(C4,J$4:J$1003,1,FALSE)),IF(ISNA(VLOOKUP(C4,L$4:L$1003,1,FALSE)),FALSE,"Match"))))

    But it's not returning the expected result. What am I doing wrong?

    Thanks in advance for the help
    JP
    Try this:

    =IF(SUMPRODUCT((MOD(COLUMN(F4:L16),2)=0)*(F4:L16=C4)),"Match")

+ 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