January 12, 2009 at 4:40 am
in my database by mistake some of the data is deleted from tables,bcoz of wrong query fired, now I want to recover the deleted rows again ........so is it possible to have my previous data again....
thanx
vaibhav agrawal
January 12, 2009 at 4:55 am
Hi,
it is possible to recover your data if the database is in full revovery model. You have to perform
1. a transaction log backup
2. restore the most recent full backup with norecovery
3. restore all (if exist) transaction log backups with norecovery
4. restore the last transaction log with recovery using the STOPAT option if you know the exact time that the wrong query has been fired.
If the database is in simple recovery model it is not possible to recover your data.
PSA
January 12, 2009 at 4:55 am
-Do you have any backups available with you before the delete?
-What is the recovery model of your database?
-Vikas Bindra
January 12, 2009 at 8:45 am
If you are in simple recovery you can restore the last full backup to another database and then copy the deleted rows (if they exist in the last backup) to the source database. I have done this when I did not want the entire database to be unavailable during a restore.
Jack Corbett
Consultant - Straight Path Solutions
Check out these links on how to get faster and more accurate answers:
Forum Etiquette: How to post data/code on a forum to get the best help
Need an Answer? Actually, No ... You Need a Question
January 12, 2009 at 9:50 am
No quick UNDO solution for sure
In additions to above methods (restore backup, find data)
you could perhaps use 3rd party tools to either
- read the trans. log for data
- use Red Gate Data Compare to compare Backup with Live DB, and sync. the missing data
January 13, 2009 at 2:54 pm
The best way will be restore the backup in a different box that is taken before deletion of the data. And if you know the query that deleted the data then just modify the query such that it selects the same data instead of deleting. And then you can export that data from there to the prod.
January 16, 2013 at 11:23 pm
Hi,
can anyone help me how to recover the old data from SQL database? The data in the database only lasts for 3months. Pleaseeeeeee this is very urgent.
January 17, 2013 at 1:00 am
Please post new questions in a new thread and give as much information as possible. Thanks,
Gail Shaw
Microsoft Certified Master: SQL Server, MVP, M.Sc (Comp Sci)
SQL In The Wild: Discussions on DB performance with occasional diversions into recoverability
Viewing 8 posts - 1 through 7 (of 7 total)
You must be logged in to reply to this topic. Login to reply