How to: Discard Changes Made to Stored Procedures and User-Defined Functions
Changes to stored procedures and user-defined functions are committed to the database only when you explicitly save them. Thus, you have an opportunity to discard changes you have made to a stored procedure or user-defined function.
Note
The procedures below only discard changes made since you last saved the stored procedure or user-defined function. For example, if you have saved changes twice already, you cannot revert to the first save.
Note
The dialog boxes and menu commands you see might differ from those described in Help depending on your active settings or edition. To change your settings, choose Import and Export Settings on the Tools menu. For more information, see Visual Studio Settings.
To discard changes made to a stored procedure
With the stored procedure open in the code editor, click Close from the File menu.
When prompted to save your changes, click No.
To discard changes made to a user-defined function
With the user-defined function open in the code editor, click Close on the File menu.
When prompted to save your changes, click No.