Oracle pagination query
SELECT * FROM (SELECT R.*, ROWNUM RNUM, COUNT(*) OVER () RESULT_COUNT FROM (SELECT i.ITEM_CODE, i.ITEM_NAME FROM TBL_ITEMS i) R) WHERE RNUM between 0 and 9 ;