Jump to content

Featured Replies

Posted

I am on 4.6.2 and got notice in admin cp that i should use InnoDB instead MYISAM -

Can i use this query to convert whole database at once or my convert table by table?

SET @DATABASE_NAME = 'name_of_your_db';

SELECT  CONCAT('ALTER TABLE `', table_name, '` ENGINE=InnoDB;') AS sql_statements
FROM    information_schema.tables AS tb
WHERE   table_schema = @DATABASE_NAME
AND     `ENGINE` = 'MyISAM'
AND     `TABLE_TYPE` = 'BASE TABLE'
ORDER BY table_name DESC;

Maybe you have beter suggestion? Can i leave MyISAM mean stay on it?

 

regards

  • 2 weeks later...
 

I am on 4.6.2 and got notice in admin cp that i should use InnoDB instead MYISAM -

Can i use this query to convert whole database at once or my convert table by table?

SET @DATABASE_NAME = 'name_of_your_db';

SELECT  CONCAT('ALTER TABLE `', table_name, '` ENGINE=InnoDB;') AS sql_statements
FROM    information_schema.tables AS tb
WHERE   table_schema = @DATABASE_NAME
AND     `ENGINE` = 'MyISAM'
AND     `TABLE_TYPE` = 'BASE TABLE'
ORDER BY table_name DESC;

Maybe you have beter suggestion? Can i leave MyISAM mean stay on it?

 

regards

Also interested in knowing.

 

Can i use this query to convert whole database at once.....

No, as that query isn't going to do any conversion.

Run the query, it gives you a series of 'ALTER...' statements that you then run against the database yourself.

Guest
Reply to this topic...

Recently Browsing 0

  • No registered users viewing this page.