Re: Import .sql file into MySQL Good Man wrote:
> "kristincollins77@gmail.com" <kristincollins77@gmail.com> wrote in
> news:1193320029.760640.275980@o80g2000hse.googlegr oups.com:
>
>> I have a SQL Enterprise database that I need to import into a MySQL
>> database. I generated a .sql file using the SQL Enterprise generate
>> script tool, and when I try to import the file. I get the following
>> error.
>>
>> ERROR 1064 (42000) at line 1: You have an error in your SQL syntax;
>> check the manual that corresponds to your MySQL server version for the
>> right syntax to use near 'IF EXISTS (SELECT name FROM
>> master.dbo.sysdatabases WHERE name = N'lobster')
>> DR' at line 1
>> "
>>
>> Any help is appreciated.
>>
>> Thanks!
>>
>>
>
> it looks like the queries in your file aren't all formatted/escaped
> properly, and that you have a syntax error near that line. open up the
> file and see what it is! early guess is that your apostrophes aren't
> escaped... ie: 'lobster' vs \'lobster\'
>
you might be better off if you export to a csv file and then import that
to mysql. |