Paging enormous tables on DB2
- by grenade
We have a view that, without constraints, will return 90 million rows and a reporting application that needs to display paged datasets of that view.
We're using nhibernate and recently noticed that its paging mechanism looks like this:
select * from (select rownumber() over() as rownum,
this_.COL1 as COL1_20_0_,
this_.COL2 as COL2_20_0_…