Solved

undo last query in mysql workbench

Posted on 2014-01-30
4
4,703 Views
Last Modified: 2014-02-08
CREATE TABLE `a_messages` (
  `a_messages_id` int(11) NOT NULL auto_increment,
  `conversation_id` bigint(20) default NULL,
  `profile_id` varchar(20) default NULL,
  `sender` varchar(20) default NULL,
  `message_id` bigint(20) default NULL,
  `message_text` varchar(1000) default NULL,
  `dateAgo` datetime default NULL,
  `message_read` tinyint(4) default NULL,
  `this_user` varchar(20) default NULL,
  PRIMARY KEY  (`a_messages_id`),
  UNIQUE KEY `unique_message_id` (`message_id`)
) ENGINE=MyISAM AUTO_INCREMENT=2110 DEFAULT CHARSET=utf8;










could I undo one delete query run in mysql workbench

delete from a_messages where this_user!='staff1'




this is a shared hosting mysql
I have not enabled remote administration for this server.  Without it this log file can not be shown.


mysql workbench is an oracle tool
0
Comment
Question by:rgb192
4 Comments
 
LVL 142

Accepted Solution

by:
Guy Hengel [angelIII / a3] earned 250 total points
ID: 39823970
short answer is :no

with MyISAM tables, you don't have transactions, so even if you had done a BEGIN TRANSACTION before, a ROLLBACK would not work (would not do anything).

so, unless you have a backup of the data BEFORE the delete, you cannot recover from the DELETE you did
0
 
LVL 76

Assisted Solution

by:arnold
arnold earned 250 total points
ID: 39823986
The following must have been done and set before this incident DB Backup and log-bin in my.cnf (transactional log) is the only way to get the data back to its state.
restore DB from backup and then replay the transactions from the transaction log up-to the point when you issued the delete.
0
 

Author Closing Comment

by:rgb192
ID: 39844718
I paid hosting company after hearing these no answers.

Thanks.
0

Featured Post

Free Trending Threat Insights Every Day

Enhance your security with threat intelligence from the web. Get trending threat insights on hackers, exploits, and suspicious IP addresses delivered to your inbox with our free Cyber Daily.

Join & Write a Comment

Suggested Solutions

Title # Comments Views Activity
Linking dictionary and columns together 2 50
Selecting specific rows 3 35
php image upload 3 27
MySQL left join performance 4 12
As a database administrator, you may need to audit your table(s) to determine whether the data types are optimal for your real-world data needs.  This Article is intended to be a resource for such a task. Preface The other day, I was involved …
Entering a date in Microsoft Access can be tricky. A typo can cause month and day to be shuffled, entering the day only causes an error, as does entering, say, day 31 in June. This article shows how an inputmask supported by code can help the user a…
Video by: Steve
Using examples as well as descriptions, step through each of the common simple join types, explaining differences in syntax, differences in expected outputs and showing how the queries run along with the actual outputs based upon a simple set of dem…
Polish reports in Access so they look terrific. Take yourself to another level. Equations, Back Color, Alternate Back Color. Write easy VBA Code. Tighten space to use less pages. Launch report from a menu, considering criteria only when it is filled…

705 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

14 Experts available now in Live!

Get 1:1 Help Now