我有.csv文件,我想使用SQL语法导入到我的数据库。这就是我的.csv文件的样子:
"john"
"james"
"peter"
"andrew"
"harry"
"king"
"hanny"
"charles"
所以我用我的SQL语法运行了这段代码:
LOAD DATA LOCAL INFILE 'C:/file.csv' INTO TABLE table FIELDS TERMINATED BY '' ENCLOSED BY '"' LINES TERMINATED BY '\n' (names)
但这是我插入时得到的:
john"
"james"
"peter"
"andrew"
"harry"
"king"
"hanny"
"charles
请如何在每行中插入每个名称