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 2000 Forums
 Transact-SQL (2000)
 Strored procedure contents deleted
 New Topic  Reply to Topic
 Printer Friendly
Author Previous Topic Topic Next Topic  

rookie_sql
Constraint Violating Yak Guru

Ireland
443 Posts

Posted - 07/11/2007 :  11:01:03  Show Profile  Reply with Quote
Hi i made a change to my SP and when i went back into it , all the code was removed what happened ?

Edited by - rookie_sql on 07/11/2007 11:03:09

Michael Valentine Jones
Yak DBA Kernel (pronounced Colonel)

USA
7020 Posts

Posted - 07/11/2007 :  11:08:37  Show Profile  Reply with Quote
You messed it up.

This is a good illustration of why you should never edit stored procedures in Enterprise Manager. Always do stored procedure work from a script in Query Analyzer.

If you don’t have the script used to create the procedure, you can recover the old version by restoring your most recent database backup to a new database, scripting out the procedure, and applying that script to your current database.



CODO ERGO SUM
Go to Top of Page

X002548
Not Just a Number

15586 Posts

Posted - 07/12/2007 :  10:26:00  Show Profile  Reply with Quote
Got a backup of the database?

Meh



Brett

8-)

Hint: Want your questions answered fast? Follow the direction in this link
http://weblogs.sqlteam.com/brettk/archive/2005/05/25/5276.aspx

Add yourself!
http://www.frappr.com/sqlteam



Go to Top of Page

jezemine
Flowing Fount of Yak Knowledge

USA
2886 Posts

Posted - 07/12/2007 :  11:58:56  Show Profile  Visit jezemine's Homepage  Reply with Quote
you should keep your scripts for each object in a source control system.


elsasoft.org
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.45 seconds. Powered By: Snitz Forums 2000