Cannot alter schema name in MYSQL 5.5 w/ MYSQL Workbench Cannot alter schema name in MYSQL 5.5 w/ MYSQL Workbench mysql mysql

Cannot alter schema name in MYSQL 5.5 w/ MYSQL Workbench


There is no RENAME available for schema names. You will have to export the schema, then import with a new database name.

This is a limitation of the MySQL server itself.


Actually, you can rename database name very easily,

  1. go to the top menu -> Database -> reverse engineering, select your database and keep go further until you get the er diagram of your database,
  2. after the there is an area called Catalog Area under that you can see your database name, right click on that and select edit schema. and change your database name
  3. now again go to the top menu -> database -> forward engineering and completed the database engineering using the wizard.


I can't imagine that anyone is still using version 5.5, but here is the procedure I followed in version 8. If you do have an older/newer version this may still work.

  1. Connect to the database.
  2. Open the Database menu and choose Migration Wizard.
  3. Start Migration.
  4. Both source and target will be the current MySQL server.
  5. Select the schema you want to rename.
  6. For Source Objects make sure all the tables are selected.
  7. Click Next and you will see a message that the source and target are the same.
  8. Now you should see a "Manual Editing" step.
  9. Under the Target Object column, click on the database name and change it.
  10. Now you can click next all the way through.
  11. Once finished you will have a newly renamed schema.

Currently my database has no indexes, stored procedures, etc. You will want to confirm all related objects are migrated as well before dropping the old database.