hi purdue. it's much easier with COUNTIFS. in B2:
=IF(COUNTIFS(Sheet2!$A:$A,$A2,Sheet2!$B:$B,B$1),"X","")

if you want it using INDEX & MATCH, it needs to be an array formula. that slows down your file where it's unnecessary for this case. have a happy new year