how to find the particular row in table?(means suppose one
table contain 10 rows , in these 10 rows how to find the
particular row(example in 10 rows i want 5 row how)?
Answer Posted / owen
-- I believe the questionner wants the 5th row
-- (only) from the data.
-- I also assume we don't have a useful ID to work with.
-- This is one way of doing it without cursors:
select top 1 <fieldname>
from <TableName>
where <fieldname> not in
(select top 5 <fieldname>
from <TableName>)
-- NB Changing the "5" in the subquery above sets which
-- row number is returned
| Is This Answer Correct ? | 0 Yes | 2 No |
Post New Answer View All Answers
What is bulkcopy in sql?
what types of replication are supported in sql server? : Sql server database administration
Mention the different types of triggers?
What is a raid and what are different types of raid configurations?
Explain the stored procedure?
How do I save a stored procedure in sql server?
How can you set the threshold at which sql server will generate keysets asynchronously?
Explain trigger and trigger types?
there is a trigger defined for insert operations on a table, in an oltp system. The trigger is written to instantiate a com object and pass the newly inserted rows to it for some custom processing. What do you think of this implementation? Can this be implemented better? : Sql server database administration
what is new philosophy for database devises for sql server 7.0? : Sql server database administration
How do I find the size of a sql server database?
SQL Server Architecture ?
Can sql servers link to other servers?
How to create database with physical files specified in ms sql server?
How to maintain a fill factor in existing indexes?