DBAsupport.com Forums - Powered by vBulletin
Results 1 to 2 of 2

Thread: Skip-M Top-N

  1. #1
    Join Date
    Mar 2001
    Posts
    109
    We can use SELECT * FROM tab WHERE rownum<=N ORDER BY to get the top n rows.

    How can I get the rows from M to N, that is, skip M rows then get top N?

    We can not use condition like rownum>=M as it is always FALSE.

    Thanks for any help.
    zm

  2. #2
    Join Date
    Nov 2000
    Location
    greenwich.ct.us
    Posts
    9,092
    This topic has been discussed many times before. Use http://www.dbasupport.com/forums/search.php and search for windowing. chrisrlong has a neat windowing technique that he patiently explains each time someone asks this question.
    Jeff Hunter

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  


Click Here to Expand Forum to Full Width