Wednesday, March 7, 2012

returning the Identity of the auto number column

Hi ,,

How to write the Sql Query to return the next generated Identity from the Sql server database.Which version of SQL Server are you using?

If <= 7.0 - have a look at @.@.identity
If 2000 - have a look at SCOPE_IDENTITY

No comments:

Post a Comment