我想加載到雲主機上的mysql表中的文件,但它是扔我語法錯誤。我的mysql版本是5.5.31。mysql版本5.5.31加載數據infile語法錯誤
mysql -u ykd202 -p -e 'LOAD DATA INFILE "home/folks/kosh/intx.csv" into TABLE history COLUMNS TERMINATED BY ',' OPTIONALLY ENCLOSED BY '"' ESCAPED BY '"' LINES TERMINATE BY '\n' IGNORE 1 LINES;' f2014
在上述語句中,f2014是數據庫名稱。而我得到的錯誤是
Enter password:
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 ' optinally enclosed by ' escaped by ' lines terminated by n ignore 1 lines' at line 1
'optinally封閉by'誤差不匹配您的代碼的一部分,所以這是很難說,如果你粘貼實際的錯誤,或自己鍵入它。 – 2014-10-09 01:47:04