+ Reply to Thread
Results 1 to 3 of 3

Thread: Need to display value based on two match criterion

  1. #1
    Registered User
    Join Date
    10-14-2008
    Location
    India
    Posts
    37

    Need to display value based on two match criterion

    HI,

    I have an excel workbook containing two sheets SHEET1 and SHEET2. The data in Sheet1 looks as below

    Item SO Source Column D
    A 123 5654
    B 65 777
    C 55 888

    And the data in Sheet2 is as below

    SO Source Item Transaction ID
    888 55 C 01232
    5654 123 A 01332
    777 65 B 03321

    I want to compare Sheet1 and Sheet2 and compare the SO and Item in both the sheets and if it matches then display the corresponding value from Sheet2 Column Transaction ID in Column D of sheet1.

    Please help me with this.

    Regards

  2. #2
    Forum Moderator zbor's Avatar
    Join Date
    02-10-2009
    Location
    Croatia
    MS-Off Ver
    Excel 2007
    Posts
    6,213

    Re: Need to display value based on two match criterion

    Here, try this:

    =LOOKUP(9.999E+307,CHOOSE({1,2},0,INDEX(Sheet2!$D$1:$D$1000,MATCH(Sheet1!A2&Sheet1!B2, INDEX(Sheet2!$C$1:$C$1000&Sheet2!$B$1:$B$1000,,),0))))
    "Relax. What is mind? No matter. What is matter? Never mind!"

  3. #3
    Forum Moderator zbor's Avatar
    Join Date
    02-10-2009
    Location
    Croatia
    MS-Off Ver
    Excel 2007
    Posts
    6,213

    Re: Need to display value based on two match criterion

    This will return 0 if no match. if you want N/A use just:

    =INDEX(Sheet2!$D$1:$D$1000,MATCH(Sheet1!A2&Sheet1!B2, INDEX(Sheet2!$C$1:$C$1000&Sheet2!$B$1:$B$1000,,),0))
    "Relax. What is mind? No matter. What is matter? Never mind!"

+ 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.2.0