1

is it possible to convert a SQL Server database file to a MySQL Database file and if so what would be the best way to go about doing this. Thanks.

1
  • @OMG Ponies Link not working Commented Feb 20, 2013 at 16:47

7 Answers 7

1

There are some programs out there that supposed to help migrate MS SQL databases to MySQL and vise versa (though such programs won't be able to convert complex databases or won't do a good job). I can't recommend one because I've never used one before.

This link might be helpful http://dev.mysql.com/tech-resources/articles/migrating-from-microsoft.html

Sign up to request clarification or add additional context in comments.

1 Comment

1

Take a look at the Migration Toolkit if your MySQL is 5.0 or later Of course you cannot expect 100% perfect transition as the other answers suggested.

Comments

1

Consider installing SQL Server Express to help get the job done. It's free, and in a pinch, you can install it in a VM if you don't have a dedicated Windows machine to get the job done.

  • attach the .mdf into SQL Server Express.
  • generate CREATE scripts for the tables, views and stored procedures, and any/all objects you need.
  • generate the data insert scripts if you want to keep the data.
  • parse through any stored procedure scripts to remove any TSQL specific implementation, and replace with MySQL equivalents. This could be a small or large amount of work, depending on how many sprocs are required to move over.
  • publish the CREATE and INSERT scripts to the target MySQL database.

Here are some screenshots on generating those scripts in SQL Server.

alt text alt text

Comments

1

In my case, this nice tool did the job very well: http://www.easyfrom.net/ (but my tables were empty. When tables have data, the tool will append a letter in each text field... You'll have to buy the tool to avoid this).

Comments

0

I do not know of other tools but this is what I have : Visual studio 2008 express (SQL Kit installed along with) MySQL full Install + Administrator toolkits (Available at their website)

Migration using these workd like a charm. So you will have no problems.

Comments

0

Have you looked at MySqls migration tool kit?

http://dev.mysql.com/doc/migration-toolkit/en/mysql-migration-toolkit-indepth-sourcedb-mssql.html

This is where I would recommend starting.

Comments

0

I did this recently. Tried the migration tool kit, and it didn't end up working too well for me. Ended up writing a lot of my own code to get the job done. Depending on the complexity of the database, it could take a lot of work. Took us a year to get the whole migration done. Oh, and once you get the table schemas and data transfered, that's when the real fun starts. Hope you don't use too many stored procedures. You'll have to rewrite all of those.

If you have a really simple schema, with a simple application, it might not be too difficult. Or if you knew you might want to migrate ahead of time, and designed for it, you might be ok. But if you have a big existing application, and there was no initial plan to migrate, it could be a huge job.

Comments

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.