简体   繁体   中英

MySQL: LOAD DATA INFILE syntax error 1064

I am trying to use LOAD DATA INFILE in MySQL like this:

LOAD DATA INFILE ‘mfsw_test.csv’ 
REPLACE INTO TABLE mfsw_curr 
FIELDS TERMINATED BY ‘,’ 
LINES TERMINATED BY ‘\n’ 
IGNORE 1 LINES;

I am getting an error:

1064 - 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 '‘mfsw_test.txt’ 
REPLACE INTO TABLE mfsw_curr FIELDS TERMINATED BY ‘,’ LI' at line 1

What am I doing wrong?

Check your quotes. the single quote should be a basic ' not the word-ified smartquote ''

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM