Fix for row number window function optimization

This doesn't look right to me. The query filters out every row before the 10th, so the result should have 10 fewer rows than `orders`.