Quantcast
Channel: How do I limit the number of rows returned by an Oracle query after ordering? - Stack Overflow
Viewing all articles
Browse latest Browse all 17

Answer by Manouchehr Rasouli for How do I limit the number of rows returned by an Oracle query after ordering?

$
0
0

you can also use following query

SELECT "ID", "COL1", "ETC.." FROM         tblTestWHERE "COL1" = "test"ORDER BY "ID" DESC  OFFSET x ROWS  FETCH NEXT y ROWS ONLY;

in this case you can skip first x rows and limit resault into next y rows.then you can play around with x and y inorder to paginate over your data.


Viewing all articles
Browse latest Browse all 17

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>