Click to See Complete Forum and Search --> : SqlHelper/Typed Params/@@Identity


Yarin
March 13th, 2005, 08:54 PM
Hi everybody,

I'm working with SqlHelper and strong-typed datasets, updating my data by means of passing in a typed datarow into the ExecuteNonQueryTypedParams function. I now need to be able to retrieve the @@Identity from the stored procedure- How could I go about this? It seems that by passing in a datarow I don't have room to play with output parameters or the like. Stumped. Thanks...

-Yarin

Boumxyz2
March 14th, 2005, 08:01 AM
Are you using a stored proc ? if so, then just return the @@Identity in your stored proc and use

ExecuteScalar

instead.