• Post Reply Bookmark Topic Watch Topic
  • New Topic

Getting identity value with MS Sqlserver

 
Vic Newman
Ranch Hand
Posts: 33
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I am using the microsoft driver for sqlserver 2000. Does anyone know how to retrieve the value for an identity column after an insert. When I tried "select @@identity from tablename" after a successful insert statement it returned a value of 0 for every row in the table. Has anyone had any success using this driver from microsoft?
Thanks
 
Happiness is not a goal ... it's a by-product of a life well lived - Eleanor Roosevelt. Tiny ad:
the new thread boost feature: great for the advertiser and smooth for the coderanch user
https://coderanch.com/t/674455/Thread-Boost-feature
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!