Mysql Alter Table Select all Tables

In case you wanted for eg: change all your innodb tables into myisam, and you didn't want to go over the tables one by one, you can do the following queries.

  1. USE information_schema;
  2. SELECT TABLE_SCHEMA, TABLE_NAME FROM TABLES WHERE TABLE_SCHEMA = "your_db_name";

If it returns what you need ?

  1. SELECT CONCAT("ALTER TABLE `", TABLE_SCHEMA,"`.`", TABLE_NAME, "` ENGINE = MYISAM; ") as MySQLCMD FROM TABLES WHERE TABLE_SCHEMA = "your_db_name";
Technology: 

Add new comment