sipirili
sipirili

Reputation: 21

Compare 5 columns with another sheet

I am trying to compare Sheet 1 row E to I and see if at any of these values matches the corresponding column C to G in sheet 2. Both sheets have the same header. If any of cells matches in sheet 2 on the same row , then I want to copy cell H from sheet 2 to cell J in sheet 1 and then copy the row in sheet1 it to another sheet - sheet3. I am not sure how to do it either using formula or VBA. Any help will be appreciated.

=IF(SUMPRODUCT(Sheet1!E2=Sheet2!C:C),--(Sheet1!F2=Sheet2!D:D)--(Sheet1!G2=Sheet2!E:E)--(Sheet1!H2=Sheet2!F:F)--(Sheet1!I2=Sheet2!G:G)"MATCH","")

Upvotes: 0

Views: 87

Answers (0)

Related Questions