SQL Server Forums
Profile | Register | Active Topics | Members | Search | Forum FAQ
 
Register Now and get your question answered!
Username:
Password:
Save Password
Forgot your Password?

 All Forums
 SQL Server 2008 Forums
 Transact-SQL (2008)
 help with creating stored procedure ?
 New Topic  Reply to Topic
 Printer Friendly
Author Previous Topic Topic Next Topic  

asp__developer
Yak Posting Veteran

74 Posts

Posted - 08/10/2012 :  16:56:14  Show Profile  Reply with Quote
I am trying to create a new stored procedure but getting error:

My SP

CREATE PROCEDURE [dbo].[supplier]

INSERT INTO supplier
(supplier_id, supplier_name)
VALUES
(24553, 'IBM');




Error
Msg 156, Level 15, State 1, Procedure supplier, Line 4
Incorrect syntax near the keyword 'INSERT'.

webfred
Flowing Fount of Yak Knowledge

Germany
8515 Posts

Posted - 08/10/2012 :  17:12:34  Show Profile  Visit webfred's Homepage  Reply with Quote
quote:
Originally posted by asp__developer

I am trying to create a new stored procedure but getting error:

My SP

CREATE PROCEDURE [dbo].[supplier]
AS
INSERT INTO supplier
(supplier_id, supplier_name)
VALUES
(24553, 'IBM');




Error
Msg 156, Level 15, State 1, Procedure supplier, Line 4
Incorrect syntax near the keyword 'INSERT'.





Too old to Rock'n'Roll too young to die.
Go to Top of Page
  Previous Topic Topic Next Topic  
 New Topic  Reply to Topic
 Printer Friendly
Jump To:
SQL Server Forums © 2000-2009 SQLTeam Publishing, LLC Go To Top Of Page
This page was generated in 0.03 seconds. Powered By: Snitz Forums 2000