SELECT
*
FROM
(
A.*,ROWNUM RN
FROM
(
TABLE_NAME) A
WHERE
ROWNUM <= 40
)
RN >= 21
*
FROM
(
A.*,ROWNUM RN
FROM
(
TABLE_NAME) A
ROWNUM <= 40