Mssql converts mysql to bitsCN.com.
Mysterious little strong & 1943
1. table structure
Use MySQL to generate the create script. Find the script to be exported and modify the column structure of the table created in the MySQL database according to the MySQL syntax.
2. export table data
Use bcp on MSSQL to export text files:
Bcp "SELECT * FROM dbname. dbo. tablename;" queryout tablename.txt-c-Slocalhostdb2005-Usa
"" Indicates the SQL statement to be exported.-c indicates that fields are separated and records are separated.-S indicates the database server and instance, and-U indicates the user name, -P specifies the password.
Use mysqlimport on MySQL to import text files to the corresponding table
Mysqlimport-uroot-p databasename/home/test/tablename.txt
-U indicates the user name,-p indicates the password, and databasename indicates the database name. The table name is the same as the file name.
BitsCN.com