G2数组公式,输入完成后不要直接回车,要按三键 CTRL+SHIFT+回车 下拉:
=INDEX(A:A,SMALL(IF((E$3:E$999={"立库","平库"})*(C$3:C$999="开始")*(MATCH(A$3:A$999&C$3:C$999&E$3:E$999,A$3:A$999&C$3:C$999&E$3:E$999,)=ROW($1:$997)),ROW($3:$999),4^8),ROW(A1)))&""