0

我想对下一行有一些疑问。我想阅读一个带有文本限定符的分隔文本

LOAD DATA INFILE 'D:/teszt2.txt' into table hamburger
    Fields terminated by ',' 
    Enclosed by '"'
    lines terminated by '\n'

文件是这样的

"650000",",103","DS SMITH RECYCLING GMBH","83064 RAUBLING, KUFSTEINER STR. 27",

我先做了柱子和桌子,我想把整个大文本读进去。所有的列都是 varchar(45) 类型,但我得到一个错误:

Error Code: 1366. Incorrect string value: '\xC1NIA S...' for column 'szallito_nev' at row 1 0.000 sec

此致

4

1 回答 1

0

我在第二列中看到一个不成对的双引号 (")。可能会将其余行作为字符串。

"650000",",103","DS SMITH RECYCLING GMBH","83064 RAUBLING, KUFSTEINER STR. 27",
         ^

应该

"650000","",103","DS SMITH RECYCLING GMBH","83064 RAUBLING, KUFSTEINER STR. 27",
于 2013-09-26T11:15:56.810 回答