Get next 10 rows from a list of records

  • Hi

    I've a list of records in a table say 100.

    for good performance I show only top 10 records.

    on selecting next button I need to show the next 10 records. how to do this.

    I'm using sql server 2000 - how to accomplish this task?

    to know more - in higher levels i.e. 2005,2008 do we have any straight forward way to get such data.

    Thanks in advance.

  • Sree-258588 (7/2/2010)


    Hi

    on selecting next button I need to show the next 10 records. how to do this.

    what "next" button?

    Are you querying from a custom application?

    -----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------
    This thing is addressing problems that dont exist. Its solution-ism at its worst. We are dumbing down machines that are inherently superior. - Gilfoyle

  • Hi

    It sounds like you're talking about paging. This page has lots of useful code for doing paging and is worth a look. It contains code for SQL 2000, as well as for SQL 2005-8 using the new ROW_NUMBER() function.

    Regards,

    Duncan

Viewing 3 posts - 1 through 2 (of 2 total)

You must be logged in to reply to this topic. Login to reply