Mysql
 sql >> Base de Dados >  >> RDS >> Mysql

Carregar xml na tabela mysql com elemento


Remova o ponto e vírgula após FIELDS TERMINATED ...

Você deve usar o LOAD XML ... Sintaxe também. Consulte http://dev.mysql.com/doc/ refman/5.5/en/load-xml.html :
The LOAD XML statement reads data from an XML file into a table

Seu LOAD DATA INFILE ... é usado para carregar um arquivo simples (csv) para uma tabela, não um XML:
The LOAD DATA INFILE statement reads rows from a text file into a table