Bobcares

Migrate and Convert SQL Server to MySQL with Workbench

PDF Header PDF Footer

Discover how to migrate and convert SQL Server to MySQL with Workbench. Our MySQL Support team is ready to assist with any queries or concerns.

Migrate and Convert SQL Server to MySQL with Workbench

The thought of migrating databases from Microsoft SQL Server to MySQL can be scary. Fortunately, the MySQL Workbench’s Migration Wizard makes the process a lot easier.

This tool automates schema conversion, data transfer, and compatibility adjustments, reducing manual effort and minimizing the risk of errors.

Today, our Experts will walk us through a step-by-step guide to migrate your database smoothly using MySQL Workbench.

Why Use MySQL Workbench for Migration?

  • Automated schema conversion
  • Bulk data transfer support
  • Cross-platform compatibility
  • Visual verification tools (EER diagrams)

MySQL Workbench can handle most processes like moving a simple table or a large database with multiple dependencies.

If you’re also looking to copy MySQL databases easily, check out this tutorial for managing MySQL data efficiently.

Step-by-Step SQL Server to MySQL Migration

Step 1. Prepare Your SQL Server Database

First, open Microsoft SQL Server Management Studio (SSMS) and select the database we want to migrate. For demonstration purposes, let’s assume we have a sample database called bc\_database, which contains a table named bobcares with five rows of data.

Step 2. Configure the ODBC Driver

This step sets up a connection bridge between SQL Server and MySQL Workbench.

  1. Open ODBC Data Sources.
  2. Then, click Add on the right side of the window.
  3. Now, scroll down and select ODBC Driver for SQL Server.
  4. Click Finish to open a configuration window.
  5. Next, enter a Data Source Name (DSN) and provide your SQL Server instance details.
  6. Click Finish to save the data source.

MySQL Workbench uses this ODBC configuration to connect to SQL Server.

Step 3. Launch the Migration Wizard in MySQL Workbench

  1. First, open MySQL Workbench and connect to the MySQL server.
  2. Then, go to the Database menu on the left.
  3. Select Migration Wizard from the dropdown.

    Migrate and Convert SQL Server to MySQL with Workbench

  4. Then, click Start Migration to begin.

If you’re working with AWS RDS databases, this guide explains how to connect MySQL Workbench to remote databases like RDS.

Step 4. Configure the Source Connection

  1. Now, select ODBC Data Source as the connection method in the source selection window.
  2. Select the DSN you created in Step 2.
  3. Then, click Test Connection to verify the setup.

If we run into an error at this stage, go back to Step 2 to ensure the ODBC configuration is correct.

If you encounter errors, double-check the ODBC configuration. Sometimes, connection issues may stem from incorrect database or user selections, similar to the “no database selected” SQL import error.

After the connection is successful, click Next to proceed.

Step 5. Select the Database to Migrate

  1. Review the list of available databases.
  2. Then, select the SQL Server database we want to migrate.
  3. Click Next to continue.

Step 6. Perform Object Migration

This step handles the conversion of database objects, like Tables, Views, and Schemas.

  1. Review Source Objects.
  2. Check the Migration Progress.
  3. Use Manual Editing if needed (for complex object adjustments).
  4. Set Target Creation Options.
  5. Then, generate the Create Schemas scripts.
  6. Confirm the Create Target Results window to validate the operation.

If everything looks correct, go to the next step.

Step 7. Transfer the Data

  1. Configure Data Transfer Setup.
  2. Execute the Bulk Data Transfer process.

If the transfer completes successfully, we will receive a confirmation message.

If your SQL Server database is large, consider breaking the transfer into chunks or using additional data management strategies. For MySQL users, you can also load SQL files directly into MySQL as an alternative method.

Post-Migration Verification

After the migration, we need to verify that everything transferred correctly.

  1. Open a MySQL SQL Editor.
  2. Run a query on the migrated database, for example:
    SELECT * FROM Northwind.categories;Copy Code
  3. Check that the tables and data are intact.

Bonus Tip – Create an EER Diagram

We can create a visual representation of our database with these steps:

  1. In MySQL Workbench, click Create EER Model From Existing Database.
  2. Follow the prompts to generate the diagram.
  3. Use Arrange > Autolayout to organize the model for easier viewing.

The EER diagram helps ensure all relationships and entities are correctly migrated.

[Need assistance with a different issue? Our team is available 24/7.]

Conclusion

In short, our Support Engineers demonstrated how to migrate and convert SQL Server to MySQL with Workbench.

0 Comments

Submit a Comment

Your email address will not be published. Required fields are marked *

Get featured on the Bobcares blog and share your expertise with a global tech audience.

WRITE FOR US
server management

Spend time on your business, not on your servers.

TALK TO US

Or click here to learn more.

Speed issues driving customers away?
We’ve got your back!