mysql - How to execute this LOAD XML INFILE SQL query? -
i have table in place i'm trying populate using data external xml file. i'm using load xml infile
function it, using query below. i'm getting #1290 - mysql server running --secure-file-priv option cannot execute statement
, query unable execute. can please enlighten me needs done can execute it?
here's query reference.
load xml infile 'c:\\users\shubham\desktop\part_info.xml' table dbtest.part_no rows identified '<row>';
i'm answering own question found answer myself.
for specifics, i'm working on windows , installed mysql in-part general wamp installation.
i tried solution @miket (in comments above) suggested. workaround mentioned was
- to move file want import directory specified
secure-file-priv
brought sql queryshow variables "secure_file_priv";
however error (for me atleast) still persisted. error resolved (again, me atleast) using forward-slashes instead of backslashes using file path, indicated following sql query
load xml infile 'd://secondary/wamp64/tmp/part_info.xml' table dbtest.part_no rows identified '<row>'
hope helps.
Comments
Post a Comment