Это может быть достигнуто с помощью промежуточной суммы.
select Item, Stay, sum(case when Stay > 8600 then 1 else 0 end) over(partition by item order by ts) as seq_group from tableA