2. In the first cell of the auxiliary column, enter function =SUBTOTAL( 103, $C$2:C2) and set the first serial number.
3. At this point, all serial numbers are set by drop-down, as shown in the figure below.
4. Finally, filter the data as needed, and you will find that the original serial number will change discontinuously, while the serial number on the auxiliary column will automatically change the order and reorder, and it is completed.