• Hi All

    Please note that at the Chandoo.org Forums there is Zero Tolerance to Spam

    Post Spam and you Will Be Deleted as a User

    Hui...

  • When starting a new post, to receive a quicker and more targeted answer, Please include a sample file in the initial post.

Formula to get result based on two criteria from different worksheet

tango

Member
Good Day! I am receiving two files from different department and usually copy/paste them on separate worksheets within my master file.

-----WorkSheet1------
FRUIT STARTsupplyDate STARTprodDate STARTfinalDate
BANANA 1/1/2017 2/2/2017 3/3/2017
ORANGE 4/4//2017 5/5/2017 6/6/2017
APPLE 7/7/2017 8/8/2017 9/9/2017


--------WorkSheet2----------
STARTsupplyCode STARTprodCode STARTfinalCode
AAA CCCC EEE
BBBB DDD FFFF


----MyMasterWorkSheet-----
Fruit Origin Code DateResult. Formula in this column required. . Sample answer shown.
BANANA USA AAA 1/1/2017
ORANGE CANADA DDD 5/5/2017
BANANA EGYPT FFFF 3/3/2017
APPLE CANADA AAA 7/7/2017


Of course, it is a long list but for shortened it for convenient purposes.

Question is what is the formula to show/get the corresponding "DATE" following the "FRUIT" and "CODE" fields as reference/criteria on MyMasterWorkSheet.
The DateResult column on MyMasterWorkSheet is the answer found based on the FRUIT field from the WorkSheet1 and CODE field from the WorkSheet2 to get the appropriate (DATE).

Hope I explain it clear but I attached is the sample file as you may find it simple to understand doing it. Appreciate your help/reply. Thank you in advance.
 

Attachments

  • CHANDOO-Question.xlsx
    10.1 KB · Views: 10
Try,

In "MyList" Sheet D2, formula copied down :

=INDEX(Expiry!B$2:D$4,MATCH(A2,Expiry!A$2:A$4,0),SUMPRODUCT((C2=Store!A$2:C$3)*COLUMN(Store!A$1:C$1)))

Regards
Bosco
 

Attachments

  • IndexAndMatch.xlsx
    11 KB · Views: 9
Back
Top