Executing SQL Script file in SQL Server 2005 created export file from MySQL
Posted on 2011-10-19
I'm in the process of transferring data from MySQL and its end destination is desired to rest in SQL Server 2005.
Using phpMyAdmin interface i can export my tables from MySQL database. I've successfully export my tables and generated SQL Script files using the mentioned interface within MySQL. Then i imported these SQL Script file into my SQL Server 2005 database and using the query Analyzer tried to run this scripts and load this data. For unknown reasons the query is failing to run.
Here is a Snippet of the code which is failing:
INSERT INTO `messages` (`ID`, `project`, `title`, `text`, `tags`, `posted`, `[user]`, `username`, `replyto`, `milestone`) VALUES
(11, 4, 'Martinelli v. Quaye', 'The arbitration hearing has been continued to December 17, 2010, at 10:30 a.m.', '', '1291734120', 2, 'Brandon Johnson', 0, 0),
(20, 6, 'Robert McDivitt''s Sect.: Donna Shilling', '', '', '1293032429', 2, 'Brandon Johnson', 0, 0),
(1146, 9, 'Arbitration Results', 'I appeared for an arbitration today 10/18/11 in Essex County. The solo arbitrator was John Scollo, Esq.. He found 100% liability on your insured which is not surprisung as this was a rear end hit situation.<br />Damages we set at $15,500 which included $5207 in documented out of pocket wage loss and $3,324 in unreimbursed medicals and $7,000 for pain and suffering.<br />The companion case ( Fogler)was also arbitrated and damages were set at $23,000 for that claim. Therefore since the two combined claims are over our remaining policy limits we will have to file a trial de novo.', '', '1318970705', 4, 'LuAnn Watson', 0, 0),
(1147, 8, 'Arbitration results', 'I appeared for an arbitration today, 10/18/11 in Essex County. The solo arbitrator was John Scollo, Esq. 100% liability was placed on us in this rear end hit situation.<br />Damages were set at $23,000 which included an undocumentated net wage loss of $2,000. Approx $9,000 was paid by PIP for Fogler''s meds so no medicals were included in the award.<br />The companion case (Basaran) was arbitrated at the same time. An award of $15,500 was placed on that matter. Since the two awards together amount to more than our remaining policy limits, this arbitration award will need to be de noved.<br />Once a trial de novo is filed you should expect to receive a trial date w/in 45 days.', '', '1318971147', 4, 'LuAnn Watson', 0, 0);
I did in fact create a table in SQL Server 2005 named 'messages' with the appropriate fields referenced above.
The error message is :
Msg 102, Level 15, State 1, Line 1
Incorrect syntax near '`'.
Not too descriptive. And appears to not like the marks surrounding each of the field names in the Insert Statement. Leads me to believe this is a syntax error, but not familiar enough with this script to know the correct syntax..
Your kind help is much appreciated.