0
点赞
收藏
分享

微信扫一扫

企业中如何批量更改mysql中表的存储引擎?

一、首先必须熟悉Mysql中有哪些基本的数据库,在mysql中database等价于schema,默认的基本库有四个:mysql,information_schema,performance_schema,sys。

 

 

二、sql语句如下:主要是获取某个库的所有表名,然后使用concat组合成一条条语句;

select concat( 'alter table ' ,table_name ,' engine=myisam; ') 
from information_schema.tables t
where table_schema
and table_type


举报

相关推荐

0 条评论