Possible Duplicate:
Mysql permission errors with ‘load data’
I am needing a PHP script that loads a large XML file into MySQL. I will be using this in a cron.
I first tried to use the DOM and XMLReader PHP libraries to parse the XML into rows that I could insert into MySQL. This file was large enough that I ran out of memory trying to deal with it. I am already at 128MB of memory in PHP.
I am trying out the LOAD XML INFILE command in MySQL. This part of MySQL is completely new to me. I had to upgrade to a newer version of MySQL so that LOAD XML is supported. I tried executing this:
LOAD XML INFILE '/path/huge_xml_file.xml'
INTO TABLE `my_table`
ROWS IDENTIFIED BY '<ROW>' ;
MySQL returned:
Error Code: 1045. Access denied for user 'db_user'@'###.###.###.###' (using password: YES)
After some reading, my understanding is that loading files from MySQL is disabled by default. I've had some trouble locating a detailed description of what I need to change on the server and where in order to get this approach to work for me.