Link to home
Start Free TrialLog in
Avatar of HLRosenberger
HLRosenbergerFlag for United States of America

asked on

returning primary key after update

I use this appended to an INSERT statement (using Dim PK as long = Command.ExecuteScalar() ) to return the primary key:

SELECT @@Identity

How do I do the same for an UPDATE?  I am geting a NULL back.
ASKER CERTIFIED SOLUTION
Avatar of Steve Wales
Steve Wales
Flag of United States of America image

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
Avatar of HLRosenberger

ASKER

I understand  Thanks!