
May 7th, 2005, 03:56 PM
|
|
Registered User
|
|
Join Date: May 2005
Posts: 2
Time spent in forums: 27 m 23 sec
Reputation Power: 0
|
|
|
Creating a Stored Procedure with Code C#
Greetings,
I am trying to create a stored procedure programatically. So far I have not been able to make it work.
The code for the SQL statement is this
"CREATE PROCEDURE sp_Stored1" +
"(@ProductID INT, @CategoryID INT, @UnitCost MONEY, @ModelNumber NVARCHAR(50)," +
"@ProductImage NVARCHAR(2000), @Description NVARCHAR(3800)) AS INSERT INTO CMRC_BargainProducts" +
"(ProductID,CategoryID,UnitCost,ModelNumber,ModelNa me,ProductImage,Description) " +
"VALUES(@ProductID,@CategoryID,@UnitCost,@ModelNumb er,@ModelName,@ProductImage,@Description)";
I need to create it programatically because I am creating a site that will go up on a remote host and I will not have access to
the database.
Thanks
|