How to use it
- 1Export your database (mysqldump or phpMyAdmin) and paste the SQL, or drop the .sql file.
- 2Read the review notes under the output — they list everything that needs a human decision.
- 3Download the SQL Server script and run it against a staging database first.
What changes between MySQL and SQL Server
AUTO_INCREMENT becomes IDENTITY(1,1), and INSERTs into those tables are wrapped in SET IDENTITY_INSERT … ON/OFF so your original ids are preserved.
VARCHAR becomes NVARCHAR, TEXT and JSON become NVARCHAR(MAX), TINYINT(1) becomes BIT, DATETIME becomes DATETIME2 and BLOBs become VARBINARY(MAX).
Multi-row INSERTs are split into batches of 1,000 rows, SQL Server's limit, and LIMIT n in queries becomes TOP (n).
What to check before you run it
Run the converted script against an empty staging database first, inside a transaction if the target supports transactional DDL. The review notes under the output list every statement that was dropped, every type with no direct equivalent and every clause that needs a manual decision.
Views, triggers, stored procedures and functions are passed through unchanged and flagged. Their bodies are written in MySQL's procedural language and need a human rewrite for SQL Server.
After loading, compare row counts table by table. For a deeper check, export a table from both databases and run the two files through the CSV compare tool.
Questions
Does this work for Azure SQL Database?
Yes. The output is plain T-SQL with no file-group or server-level options, so it runs on SQL Server 2016+ and Azure SQL.