Wednesday, March 28, 2012

rowid is there?

Hi experts,
I'm in need to use the rowid of a column.
is there any concept like rowid?

for example, i need the first row of a table.or 5th row of a table.how can i write the query?

thank you verymuch in advance.

Quote:

Originally Posted by vinod

Hi experts,
I'm in need to use the rowid of a column.
is there any concept like rowid?

for example, i need the first row of a table.or 5th row of a table.how can i write the query?

thank you verymuch in advance.


select top 1 * from tablename|||Add a column of int datatype to the existing table. Define identity on that column. Define Identity seed and identity increment as 1,1.
The following is the syntax.

a int identity(1,1). Here a is the column. SQL Server automatically increments the number. Based on that number you can fetch the desired record.|||Using Identity function is really great friend.
I'm trying for my purpose now, if i need some more assistance, i'l come back to you

No comments:

Post a Comment