从 Microsoft SQL Server 到 MySQL 的转换
声明:本页面是StackOverFlow热门问题的中英对照翻译,遵循CC BY-SA 4.0协议,如果您需要使用它,必须同样遵循CC BY-SA许可,注明原文地址和作者信息,同时你必须将它归于原作者(不是我):StackOverFlow
原文地址: http://stackoverflow.com/questions/6584093/
Warning: these are provided under cc-by-sa 4.0 license. You are free to use/share it, But you must attribute it to the original authors (not me):
StackOverFlow
Conversion from Microsoft SQL Server to MySQL
提问by Anil Vadhavane
How do I convert a Microsoft SQL Server database backup file such that to import in MySQL database? Is there any way or free tool available for this?
如何转换 Microsoft SQL Server 数据库备份文件以便导入 MySQL 数据库?有什么方法或免费工具可用于此吗?
回答by Icemanind
Not sure about how complex a database you have, but if its just some tables and data, there is a free script herethat will automagically convert Microsoft SQL Server tables and data over to MySQL.
不确定您拥有的数据库有多复杂,但如果它只是一些表和数据,这里有一个免费脚本可以自动将 Microsoft SQL Server 表和数据转换为 MySQL。
If you need something more sophisticated, then MySQL has a migration toolkitwhich allows you to migrate from Microsoft SQL Server to MySQL. In addition here is a tutorialon how to use it. Note that this has now been discontinued, in favor of MySQL Workbench, which has data migrationbuilt in.
如果您需要更复杂的东西,那么 MySQL 有一个迁移工具包,它允许您从 Microsoft SQL Server 迁移到 MySQL。此外,这里有一个关于如何使用它的教程。请注意,这现已停止,取而代之的是MySQL Workbench,它内置了数据迁移。
In addition, this converterwill convert everything except stored procedures from MSSQL to MySQL, for a price of only $50 which isn't bad.
此外,这个转换器可以将除存储过程之外的所有内容从 MSSQL 转换为 MySQL,价格仅为 50 美元,这还不错。
Also you may want to check out this whitepaperfrom MySql's website on how to plan a migration from SQL Server to MySQL, as well as some resources.
此外,您可能还想查看MySql 网站上的这份白皮书,了解如何规划从 SQL Server 到 MySQL 的迁移,以及一些资源。
回答by JClaspill
ms2my (Pre-Alpha, free) http://sourceforge.net/projects/ms2my/
ms2my(Pre-Alpha,免费) http://sourceforge.net/projects/ms2my/
"A tool that helps with MSSQL to MySQL converting/replicating (both csv&dump) under *nix.Possible to use it with crontab for regular data fetching.Keeping mySQL-based data warehouse refreshed could also be one of the possibilities of using this script."
“在 *nix 下帮助 MSSQL 到 MySQL 转换/复制(包括 csv 和转储)的工具。可以将它与 crontab 一起使用以进行常规数据获取。保持基于 mySQL 的数据仓库刷新也可能是使用此脚本的可能性之一。 ”
MSSQL to MySQL Converter (free trial download, for purchase $49) http://www.convert-in.com/mss2sql.htm
MSSQL 到 MySQL 转换器(免费试用下载,购买 49 美元) http://www.convert-in.com/mss2sql.htm
I've looked for quite awhile, and if you don't want to try ms2my, the above is about the only other option. And it isn't free.
我已经找了一段时间了,如果您不想尝试 ms2my,以上是唯一的其他选择。而且它不是免费的。
Best of luck finding a free one, hopefully there is one that is hidden away out there on the internet that I can't find.
祝你找到一个免费的好运,希望有一个隐藏在互联网上的我找不到。
回答by Eduardo Lago Aguilar
If you are using a living MS SQL Server and a living MySQL server, then I think your best AND MORE ACCURACYoption is to use an ETL/data transformation tool like Pentaho Data Integration(Kettle).
如果您使用的是活的 MS SQL Server 和活的 MySQL 服务器,那么我认为您最好且更准确的选择是使用ETL/数据转换工具,如Pentaho Data Integration( Kettle)。
With Kettle you can visually design (using easy-to-learn data flow steps) almost any data transformation from single/multiple data source(s) to single/multiple data destination(s). One of the features you may be interested is the database/tables migration wizard.
使用 Kettle,您可以直观地设计(使用易于学习的数据流步骤)从单个/多个数据源到单个/多个数据目标的几乎任何数据转换。您可能感兴趣的功能之一是数据库/表迁移向导。
If the community distribution of Kettle is not enough for you, then you can use the Enterprise Editionwith more features, support, etc.
如果Kettle的社区分发对你来说还不够,那么你可以使用具有更多功能、支持等的企业版。
回答by CloudyMarble
Take a look at Omega Syncit supports export import and synchronisation between different DBMS's including Schema and table data.
看看Omega Sync,它支持不同 DBMS 之间的导出导入和同步,包括模式和表数据。