MySQL Forums
Forum List  »  General

Problem when copying Query from Excel to MySQL
Posted by: David Jödicke
Date: May 04, 2017 05:55AM

Hey guys,

I want to alter my table with a lot of new columns. I have the names of the columns in an Excel-Sheet. To insert these new columns easier into my database I have written a formula in Excel which creates the query for altering my table.
When I copy this query to my MySQL-Console and try to execute it i got an error:

"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 'ALTER TABLE webdb ADD mail_adress VARCHAR(16) NULL AFTER name' at line 1"

When I am writing the same query manualy and execute it the query works. Even when I write the query in Notepad and copy it from there it is working... I only have this problem when I copy it from Excel.
Copying from Excel to Notepad and then to MySQL doesn_t work either.

Maybe you have some ideas?

Thank you,

David

Options: ReplyQuote


Subject
Written By
Posted
Problem when copying Query from Excel to MySQL
May 04, 2017 05:55AM


Sorry, you can't reply to this topic. It has been closed.

Content reproduced on this site is the property of the respective copyright holders. It is not reviewed in advance by Oracle and does not necessarily represent the opinion of Oracle or any other party.