开发者

mysql truncate archive table

开发者 https://www.devze.com 2023-04-11 13:45 出处:网络
I have a table with the archive storage开发者_如何学运维 engine and I would like to clear it. Neither delete, nor truncate will work because of the engine definition. But is there any other way than d

I have a table with the archive storage开发者_如何学运维 engine and I would like to clear it. Neither delete, nor truncate will work because of the engine definition. But is there any other way than dropping the whole table an recreating it?


Another workaround would be to change it to be a BLACKHOLE table, then change it back.


See Bug #15558 truncate doesn't clear table on archive storage engine tables

Basically, the designers wanted it to work that way. The fix to that bug was to make it return an error when you try to use truncate on a table stored with the ARCHIVE storage engine.

The only workaround is to DROP and the re-CREATE the table.

0

精彩评论

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