.NET Diary

January 21, 2009

Syntax error in TextHeader of StoredProcedure

Filed under: All, Javascript, SQL — leoullas @ 8:46 am

Microsoft SQL Server Management Studio get this error when trying to modify script the above stored procedure



Script failed for StoredProcedure ‘dbo.usp_Edit_User’.  (Microsoft.SqlServer.Smo)

Syntax error in TextHeader of StoredProcedure ‘usp_Edit_User’. (Microsoft.SqlServer.Smo)


You have nested comments before your ALTER PROC, which is not possible in TSQL.  Change your header.



exec usp_Edit_User @Company_Id=N’9003′, @User_Id=N’WWWWWWWWWWWWWWWWWWWW’,/* @Password=N’dris#12345′,*/ @User_Name=N’cWWWWWW’, @Role_Id =N’1′, @Branch_Id=N’13001′, @Is_Locked=N’True’, @Active_Flg=N’Y’, @Modified_By=N’Test_001′, @UserTimeStamp=N’106060′




exec usp_Edit_User @Company_Id=N’9003′, @User_Id=N’WWWWWWWWWWWWWWWWWWWW’, @User_Name=N’cWWWWWW’, @Role_Id =N’1′, @Branch_Id=N’13001′,@Is_Locked=N’True’,@Active_Flg=N’Y’, @Modified_By=N’Test_001′, @UserTimeStamp=N’106060′



  1. How do you edit the comment if you are unable to open the SP in the first place?

    Comment by Simon — October 28, 2009 @ 9:32 am

    • You may open your SP in notepad or saome other operation.

      Comment by leoullas — October 28, 2009 @ 10:06 am

  2. How?

    Comment by Miguel — October 10, 2011 @ 11:50 pm

RSS feed for comments on this post. TrackBack URI

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out /  Change )

Google+ photo

You are commenting using your Google+ account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )


Connecting to %s

Blog at WordPress.com.

%d bloggers like this: