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
 SQL Server Development (2000)
 record unique identifier

Author  Topic 

AskSQLTeam
Ask SQLTeam Question

0 Posts

Posted - 2001-10-05 : 09:49:20
Florin Rapan writes "MS SQL Server 7
Windows NT 4.0

I have to retrieve a number of records from several tables; some of them have IDENTITY columns, other don't. The business app logic dictates that the SELECT statement HAS to mention an identity interval, such as:

"SELECT columnName, (...other) FROM tableName WHERE columnName > startIndex AND columnName < endIndex"

Is there a unique identifier for each record stored in a table in MS SQL Server OR a function that would return it, REGARDLESS of whether an identity column has been defined for that table?

I know one can retrieve the OBJECT_ID or DB_ID, but I could not find a function that would return an identifier for a particular record.

My team-leader is conviced there should be one :)

Many thanks,
Florin"
   

- Advertisement -