Please start any new threads on our new
site at https://forums.sqlteam.com. We've got lots of great SQL Server
experts to answer whatever question you can come up with.
| Author |
Topic |
|
DBASlut
Yak Posting Veteran
71 Posts |
Posted - 2006-03-17 : 15:43:06
|
| I'm attempting to output a file from MySQL so I can import into SQL Server..having problems with MySQL and their documentation..SELECT *FROM your_tableINTO OUTFILE '\path\to\your_file.csv'FIELDSESCAPED BY ''LINESTERMINATED BY '\r\n';is supposed to represent NULLS as '', but it doesn't.. help? |
|
|
eyechart
Master Smack Fu Yak Hacker
3575 Posts |
Posted - 2006-03-17 : 15:49:25
|
| use the mysqldump command instead. this will output DDL for your tables as well as DML for the inserts.You will have to edit the file and change some datatypes to what SQL Server expects, but that is not hard.ANother solution is to use SQL DTS. You will need to install the MySQL ODBC driver on your SQL Server for this to work. This is probably the easiest way to move data from MySQL to SQL Server.-ec |
 |
|
|
DBASlut
Yak Posting Veteran
71 Posts |
Posted - 2006-03-17 : 16:24:10
|
| eyechart,I tried DTS using the MySQL ODBC driver but when I tried to DTS a 2million records table, it died 'Client out of memory'..MySQL's help is a joke.. I did the mysqldump, but that would mean 2million inserts.. |
 |
|
|
|
|
|