Hi,
I would recommend use of SQL statement to filter records because SET FILTER is very slow if your dataset is large. Then, you could use _TALLY = 0 or RECCOUNT() = 0 to check for empty cursor.
HTH
I am not the most powerful man in this world.
I am not the worst man in this world either.
I just as same as all of you.
I still need to learn from my mistakes...