exp:ezconvertmysqltabletype
Convert the tables of a MySQL database to another table type (--list, --newtype=TYPE).
Script bin/php/ezconvertmysqltabletype.php, code in kernel/private/classes/commands/ezconvertmysqltabletype.php. Run it from the installation root, as the user the web server runs as:
./console exp:ezconvertmysqltabletype --help
php bin/php/ezconvertmysqltabletype.php --helpOptions
| Option | Value | Help |
|---|---|---|
--host | required | Connect to host database |
--user | required | User for login to the database |
--password | required | Password to use when connecting to the database |
--database | required | |
--list | List the table types | |
--newtype | required | Convert the database to the given type. Type can either be: myisam or innodb Make sure that you have made a BACKUP UP of YOUR DATABASE! |
--usecopy | To convert the table we rename the original table and copy the data to the new table structure. This conversion method is much slower and has a higher risk to corrupt the data in the database. However this option may circumvent the MySQL crash on the ALTER query. |
Read from the option definitions in the code (startup(), getOptions(), options() or ezcConsoleOption). Every script also takes the standard options of the script framework (--help, --siteaccess, --debug, --quiet, --allow-root-user ...).
Related
Generated by ./console exp:help:examples from bin/php/ezconvertmysqltabletype.php, kernel/private/classes/commands/ezconvertmysqltabletype.php. Do not edit this page: change the source and generate again (how). Free documentation: GFDL 1.3 or later.