SELECT @@IDENTITYSELECT SCOPE_IDENTITY()SELECT IDENT_CURRENT('TableName')SELECT MAX(primeryleyid) FROM TableNameSELECT TOP 1 primeryleyid FROM TableName ORDER BY primeryleyid DESC
Login to post response