• This site uses cookies. By continuing to use this site, you are agreeing to our use of cookies. Learn more.

XF 1.1 Changing tables from MyISAM to InnoDB

#1
We have a very big database at the TechSpot Forums but when we switched we didn't notice we had InnoDB disabled, now we want to change them to the InnoDB tables. We've looked around the forum and know that there are some tables that should use MyISAM and Memory.

Repost from: http://xenforo.com/community/threads/mysql-myisam-or-innodb.388/page-4#post-356135

I've created a SQL script that alters only the required tables to InnoDB from MyISAM. See attached.

Basically it does something like this:
Code:
SET FOREIGN_KEY_CHECKS = 0;
 
ALTER TABLE xf_addon ENGINE=InnoDB;
...
ALTER TABLE xf_warning_definition ENGINE=InnoDB;
 
SET FOREIGN_KEY_CHECKS = 1;
I'm not sure if disabling foreign key checks is necessary but it might prevent issues when switching. Any thoughts?
 

Attachments