jbruns Posted November 19, 2003 Share Posted November 19, 2003 Hi there- I accidently executed a mysql command \"DELETE FROM `responses` WHERE `obj_id` > 123. What I really meant to say was delete the row where obj_id = 123. Needless to say I delete ALL my data. Fortunately I backup all my tables every night, however, this won\'t reflect anything that was input after 3am. I\'ve logged in as root and am looking at my tables under /var/lib/mysql/ and it considering the size of the file, I think the data is still there, although I can\'t access it. I have 3 files: res.frm --> 16396 res.MYD --> 544360 res.MYI --> 1389568 Judging by the size, I assume the data is still intact, however it\'s just a matter of retrieving it. I issued a ROLLBACK command, immediately after I made the deadly delete mistake, and it said it was executed successfully, however, it still reads as have 0 rows. Any suggestions?? Thanks! Link to comment https://forums.phpfreaks.com/topic/1393-rollback-question/ Share on other sites More sharing options...
shivabharat Posted November 19, 2003 Share Posted November 19, 2003 What MYSQL Says :?: By default, MySQL runs in autocommit mode. This means that as soon as you execute an update, MySQL will store the update on disk. If you are using transactions safe tables (like InnoDB, BDB, you can put MySQL into non-autocommit mode with the following command: SET AUTOCOMMIT=0 So your Roll back will not be useful because you havent executed them as a transaction. If you have backed up tables try restoring them Link to comment https://forums.phpfreaks.com/topic/1393-rollback-question/#findComment-4633 Share on other sites More sharing options...
jbruns Posted November 19, 2003 Author Share Posted November 19, 2003 Yeah, that\'s what I figured, I just thought due to the size of the files, maybe there was some way to do it through a back door. Link to comment https://forums.phpfreaks.com/topic/1393-rollback-question/#findComment-4635 Share on other sites More sharing options...
Recommended Posts
Archived
This topic is now archived and is closed to further replies.