Getting the value of the primary key after INSERT

  • Thread starter Thread starter Timothy
  • Start date Start date
T

Timothy

Hello,

I know there's a way to get the primary key of the record you just
inserted into the database with @ID or something, but I don't remember
exactly how.

Using MSAccess & C#

Thnx.
 
Paul said:
¤ Hello,
¤
¤ I know there's a way to get the primary key of the record you just
¤ inserted into the database with @ID or something, but I don't remember
¤ exactly how.
¤
¤ Using MSAccess & C#

If you are using a Jet 4.0 database (2000 or higher) see the following:

http://msdn.microsoft.com/library/d...cpconRetrievingIdentityOrAutonumberValues.asp


Paul ~~~ (e-mail address removed)
Microsoft MVP (Visual Basic)

Thank you both for your help, and also for helping with my compacting
problem
 
Back
Top