Kavita B

Kavita B

  • NA
  • 123
  • 184k

Insert ,delerte,update data using stored procedure

Apr 7 2011 9:39 PM
Hi,

I have read this article from this site:Using Stored Procedure in ASP.NET
but it gives errors and its not correct...What is the correct way to use stored procedure in asp.net? To insert/update/delete using stored procedure do we need to write 3 different procedures? I have a bit of confusion.. Like i have written procedure to insert data into a table using stored procedure like this
CREATE PROCEDURE INSERTRECORD
(@ID bigint,Name Varchar(25))AS
INSERT INTO TEST(ID,Name)VALUES(@ID,@Name)

Same way to update and delete also do i need to write procedures?
I have checked forum but nowhere found right way to use in in asp.net?

Answers (3)