Changes for support select page queries using row number for Oracle 10 and Sql Server 2005