# index and match 2 criteria with COUNTIF

I know many questions have been asked for using INDEX and MATCH with criteria and returning a unique list without duplicates. And I have that much working. But I ran into a problem.

Here is my data:

Here is the list i uniquely generate:

The problem is, it skips Tom Smith because it thinks that Smith, Tom is a duplicate so it removes it. This is a problem. Here is the formula I'm using:

=INDEX('C:\path\to\file\[schedule sample.xlsx]Sheet1'!$B$2:$B$108, MATCH(0, COUNTIF($A$2:A2, 'C:\path\to\file\[schedule sample.xlsx]Sheet1'!$B$2:$B$108), 0))

how do I prevent the problem of excluding names if only column B matches?

With formulas, you would need to put into E2 =B2&'|'&C2&'|'&D2 and copy it down. Then you run your whole copy-to-another-sheet logic on the E2 column only, and in the target sheet, split the string again at the '|' into three columns.