tag:blogger.com,1999:blog-5098208425613902582.post6734580764472607924..comments2023-05-24T04:03:44.929-07:00Comments on Tips and Tricks for SQL Server Developers: How to find missing Identity/Sequence numbers using T-SQL?SQL BI Devhttp://www.blogger.com/profile/05174359128365572180noreply@blogger.comBlogger5125tag:blogger.com,1999:blog-5098208425613902582.post-73294962695914906952013-07-06T10:05:41.718-07:002013-07-06T10:05:41.718-07:00excellent piece of information, I had come to know...excellent piece of information, I had come to know about your website from my friend kishore, pune,i have read atleast 8 posts of yours by now, and let me tell you, your site gives the best and the most interesting information. This is just the kind of information that i had been looking for, i'm already your rss reader now and i would regularly watch out for the new posts, once again hats off to you! Thanx a lot once again, Regards, <a href="http://oracletechniques89.blogspot.com/2013/04/difference-between-sql-and-tsql.html" rel="nofollow">Difference sql and tsql<br /></a><br /><br /><br /><br />Anonymoushttps://www.blogger.com/profile/17313661190126567875noreply@blogger.comtag:blogger.com,1999:blog-5098208425613902582.post-69062762386592233552013-07-02T03:45:06.871-07:002013-07-02T03:45:06.871-07:00Nice post very helpful
dbakingsNice post very helpful<br /><br /><a href="http://dbakings.com/sqldatabase/sqlidentity.aspx" rel="nofollow">dbakings</a>Anonymoushttps://www.blogger.com/profile/14178155909391788234noreply@blogger.comtag:blogger.com,1999:blog-5098208425613902582.post-33183802181530094462013-04-13T15:27:39.261-07:002013-04-13T15:27:39.261-07:00Good catch Krathi... I guess it is a bug. You can ...Good catch Krathi... I guess it is a bug. You can try following queries to initialize @MaxID:<br /><br /><br />DECLARE @MaxID INT = IDENT_CURRENT('dbo.TestData')<br />SELECT @MaxID <br /><br />--OR--<br /><br />DECLARE @MaxID INT = (SELECT CAST(last_value AS INT) FROM sys.identity_columns WHERE object_id = object_id('dbo.TestData'))<br />SELECT @MaxID SQL BI Devhttps://www.blogger.com/profile/05174359128365572180noreply@blogger.comtag:blogger.com,1999:blog-5098208425613902582.post-50238966495415514952013-04-12T03:51:42.777-07:002013-04-12T03:51:42.777-07:00Hi,
DELETE dbo.TestData WHERE ID IN (3,7,8,10,12,1...Hi,<br />DELETE dbo.TestData WHERE ID IN (3,7,8,10,12,13)<br /><br />In the above statement if i include 15 say DELETE dbo.TestData WHERE ID IN (3,7,8,10,12,13,15)<br /><br />The query you used didn't find the 15...since the max value now get changed to 14... or if we delete last 5 records then also we are not able to trace out the records<br />karthihttps://www.blogger.com/profile/02680081358884623499noreply@blogger.comtag:blogger.com,1999:blog-5098208425613902582.post-87550842588099457222012-10-10T21:32:54.381-07:002012-10-10T21:32:54.381-07:00Good.......Good.......jjthomashttp://www.blogger.com/profile/15834330327353132647noreply@blogger.com