I m vinod kotiya and i m from bhopal....
Once Worked in Himalayas for 6 years.
This blog is all about few how to's... music...games and softwares made by me.. nd.. the places i visited etc.
Sunday, November 20, 2011
ASP.net Scope_Identity () equivalent for mysql, LAST_INSERT_ID()
I've looked all over for this answer and had to resort to several resources. I wanted to post this here because it was so hard for me to find a simple example. If it exist other places then please excuse my post and put references to it on a reply.
So, How do I return the Primary Key Identity when I click the control with the 'Insert' command on a FormView? (With very least minimal code) get the ID - the primary key - of the newly inserted row when adding a
new record to the database using a FormView Control on a web page
With SQL Server we do it like this : (Add new insertparameter ID with direction output)