Some queries behave like ``` select seq, sleep(1) from seq_1_to_10000
Examples
One class of queries is data comparison:
select * from a where not exists (select 1 from b where b.x = a.x);
Or checking (CHECKSUM_IS_OK() being an expensive stored function):
select * from t where not CHECKSUM_IS_OK(t.x);
The moment the first row appears, you know that the datasets are different. When you have seen 10 rows, you know the structure of the data missing in b and you can kill the query and debug. If no rows appear, of course the comparison has to run to the end.