var sidebar_align = 'right';
var content_container_margin = parseInt('290px');
var sidebar_width = parseInt('270px');
Unanswered: Selecting a particular row....
how do I select only second row or 4-10 rows in the select statement
not using Cursor and fetch statements ??
thanx in advance
Use the TOP keyword in the statement with the number (or percentage) of records you want.
select TOP 2 * from sysobjects
thanx for the reply.
Actually this won't work if I need to retirieve only the 2nd row of a ceratin resultset or even a resultset of Row No 4 to Row No 10
Then you have to get fancy -
select top 6 * from sysobjects where name not in (select top 4 name from sysobjects order by name) order by name
will return #s 4 - 10
select top 1 * from sysobjects where name not in (select top 1 name from sysobjects order by name) order by name
will return the 2nd row
I have had to use this quite a bit and once you figure it out, it is handy.
Hope this helps
Last edited by freeloader; 03-05-02 at 09:36.