开发者

MySQL and truncate

I just ran truncate statement on a table and committed. What options do I have to restore the table to the state pre truncate?

Edit: I did this in my dev setup, hence nothing to 开发者_如何学编程worry for me, I was just curious to know do I have any options.


You are probably out of luck, sir. If you cannot restore from backup / replay logs (because you don't have them), then your next option is forensic recovery. That's beyond trying to explain. To succeed at that, you need to take the machine offline before anything else is written. Copy the whole disk if its MyISAM tables, or just the InnoDB files if it's InnoDB. Find an expert who can read the file internals and maybe you'll get it back.

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜