记一次修改数据库引擎的方法

select concat('alter table ',table_schema,'.',table_name,' ENGINE=NDBCLUSTER;')
 from information_schema.TABLES
 where table_schema in (select schema_name from information_schema.schemata where schema_name not REGEXP 'information_schema|sys|mysql')
 AND (ENGINE='InnoDB' or ENGINE='MyISAM');

posted @ 2016-06-12 14:57  nbuntu牛班图  阅读(211)  评论(0编辑  收藏  举报