declare @tablename varchar(100)
set @tablename = ‘Product’
if exists (select 1 from sys.columns sc inner join sys.objects so on so.Object_Id = sc.Object_Id where sc.name = ‘Id’ and sc.is_identity = 1 and so.Type = ‘U’ and so.Name = @tablename)
print ‘Table has an identity column named id’
This can be used to determine if the reseed function can be called on a table.