Click here to Skip to main content
15,892,059 members
Please Sign up or sign in to vote.
0.00/5 (No votes)
SQL
CREATE PROCEDURE HELLO @REMARKS VARCHAR (20) -- <-This Line Shows Error
AS Begin

End
Posted

1 solution

You probably have more statements than this in the Management Studio and you run them all at the same time. Procedure creation should be the only statement in a batch.

For example the following would cause a problem
SQL
select getdate()

CREATE PROCEDURE HELLO @REMARKS VARCHAR (20) -- <-This Line Shows Error
AS Begin
  print 'Hi';
End

Perhaps the easiest way to tackle this is using mouse to select the create procedurio portion and then run it. This way only the selection is executed
 
Share this answer
 

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900