Hi everyone,
I face a problem in my excel formula for sorting a status of an item.
Here a ss of the excel
pls.png

I want the status of material code in data 2 is come from data 1 that has been sorted and the CANCEL and TECO result will be excluded as shown in the picture above.

Here the formula that i use but didn't work
=IFERROR(IF(OR(VLOOKUP(G3;A3:C14;3;FALSE)={"CANCEL";"TECO"});"";INDEX(C3:C14;MODE.SNGL(IF(B3:B14=G3;ROW(C3:C14))-ROW(INDEX(C3:C14;1;1))+1)));"")
Can you fix my formula so that the result is shown as the ss?
Thank you
Excel DATA 1.xlsx