Knowledge - Details
Date Added: 6/30/2017
When you try to Modify an existing stored procedure in Microsoft SQL Server Management Studio, you may get the error Syntax error in TextHeader of StoredProcedure, and it will not allow you to view the sproc. You may think the sproc is lost forever, but there is an easy workaround to get access to its code again:
Replace xxxxxxxxxxxxx with your sproc name:
When you run that command, it will give you the sproc text. From there, you can hopefully fix the script and update it to fix the error.
Disclaimer: Everything on this website is written for my own use. I disclaim any guarantees that the procedures and advice listed here are accurate, safe, or beneficial for anyone else. If you attempt to follow any procedures or advice shared here, you do it at your own risk. Part of IT work is knowing how to recover from problems.