CSV-Import can not handle a path with 'blank'

[expired user #8874]'s profile image [expired user #8874] posted 10 years ago in General Permalink
Hello,

if you try to import a csv-file, which is located in a folder with a blank in the path, you get an error:

"Errcode: 2 - No such file or directory"

F.ex: "C:\my folder\import.csv"


Thx
ansgar's profile image ansgar posted 10 years ago Permalink
Using the latest HeidiSQL nightly build, I cannot reproduce that. The executed query is as follows:

LOAD DATA LOW_PRIORITY LOCAL INFILE 'C:\\temp\\test file.csv' INTO TABLE `test`.`test` CHARACTER SET latin1 FIELDS TERMINATED BY ';' ENCLOSED BY '"' LINES TERMINATED BY '\r\n' IGNORE 1 LINES (`t`);


Perhaps update HeidiSQL if not already done so?
ansgar's profile image ansgar posted 10 years ago Permalink
Even when the folder and the filename have blanks, it works as expected:
LOAD DATA LOW_PRIORITY LOCAL INFILE 'C:\\temp\\my folder with blanks\\ratings old.csv' INTO TABLE `test`.`test` FIELDS TERMINATED BY ';' ENCLOSED BY '"' LINES TERMINATED BY '\r\n' IGNORE 1 LINES (`t`);


What does the query look like on your side?
[expired user #8874]'s profile image [expired user #8874] posted 10 years ago Permalink
You're right! ;)

I tested every scenario
('folder and file without blanks','folder without blanks | file with blanks','folder with blanks | file without blanks','folder with blanks | file with blanks')
which all works fine. :D

In my case, in the path was a mutation!
LOAD DATA LOW_PRIORITY LOCAL INFILE '[...]Ü[...]


This is the cause if the error ...

Please login to leave a reply, or register at first.