[ACCEPTED]-Inserting from MS SQL Server to MySQL database-sql-server

Accepted answer
Score: 20

If you want to do this regulary

  • LinkedServer and OPENQUERY could be good, if you are moving not too much records per cycle.
  • Integration Services Package is a good solution if you want to move lots of data (like thousands or millions of rows).

You can schedule 1 them with SQL Server Agent.

The INSERT is a bit tricky with OPENQUERY:

INSERT INTO OPENQUERY (MYSQL, 'SELECT * FROM MySQL_Table')
SELECT * FROM dbo.SQLServer_Table

OR

INSERT INTO OPENQUERY (MYSQL, 'SELECT * FROM MySQL_Table')
VALUES ('Value1', 'Value2', ...)

More Related questions