Hi Folks
I have a very simple SP to delete a record with a passed-in (key) value. I have essentially the same procedure in place on another table and it works fine, this one does not work (the record does not get deleted). I have made certain that the correct key value is being sent in the procedure call.
I have been trying to figure this out all weekend, I don't understand what I could be doing wrong.
Any ideas?
Craig
I have a very simple SP to delete a record with a passed-in (key) value. I have essentially the same procedure in place on another table and it works fine, this one does not work (the record does not get deleted). I have made certain that the correct key value is being sent in the procedure call.
Code:
ALTER PROCEDURE [dbo].[spMCommDelRec]
@Par1 Varchar(50)
AS
BEGIN
-- SET NOCOUNT ON added to prevent extra result sets from
-- interfering with SELECT statements.
SET NOCOUNT ON;
-- Insert statements for procedure here
DELETE FROM Commodity WHERE CommodityName = '@Par1';
END
I have been trying to figure this out all weekend, I don't understand what I could be doing wrong.
Any ideas?
Craig