Fix pagination for reports
|Reported by:||Christian Boos||Owned by:||Christian Boos|
We just noticed that the way we implemented paginated reports (#216) simply makes some buggy assumptions about SQL subqueries.
In short, when one does:
SELECT * (SELECT ... FROM ... ORDER BY <criterion>) LIMIT x OFFSET y
there's absolutely no guarantee that the order defined by
<criterion> in the inner query will be kept in the final result…
See this discussion thread in trac-dev.
Pagination for custom queries is not affected by this problem.