Please start any new threads on our new site at https://forums.sqlteam.com. We've got lots of great SQL Server experts to answer whatever question you can come up with.

 All Forums
 SQL Server 2000 Forums
 Transact-SQL (2000)
 How to get row 10 to 15??

Author  Topic 

hansboin
Starting Member

11 Posts

Posted - 2006-12-05 : 02:42:20
Hi Guys,
I need to know how to get these five rows from a table.
I tried something with a double "select top" queries.
But always the last row (newest) will not be shown.

Does some one have an idea for me or a good code example which I can change to my needs.

Thanks in advance.
cheers
Hans

SwePeso
Patron Saint of Lost Yaks

30421 Posts

Posted - 2006-12-05 : 03:07:23
select top 5 * from (select top 15 * from yourtablenamehere order by somecolumnnamehere) q order by somecolumnnamehere desc


Peter Larsson
Helsingborg, Sweden
Go to Top of Page
   

- Advertisement -