forums › forums › SQLyog › Using SQLyog › Problem Importing Data From Csv When Using Sqlyog Under Parallels
- This topic is empty.
-
AuthorPosts
-
-
July 17, 2010 at 12:16 pm #12043jrwMember
I am using SQLyog on a mac using the Parallels VM. It works pretty well for most things but when trying to import data into a table from a csv file using the Table>Import data from CSV… option, I get an error “Could not open file. 123 The File name, Directory name or volume label syntax is incorrect”.
The file I am trying to import is held on the 'Windows' desktop.
Would appreciate any pointers as to what the problem is or a work round.
Thanks
-
July 17, 2010 at 6:32 pm #31101peterlaursenParticipant
What is the SQlyog version? There are different ways to import from CSV-files (depending on SQLyog version). Are you using the option to use LOAD DATA syntax or the ODBC-based option?
I think from your description it is LOAD DATA and in that case you can see the SQL-statement executed by SQLyog in HISTORY tab. If you find the statement there it will likely also fail from the editor (or any other client)- Please check.
It looks very much like an issue with mapping of drive letters in 'parallels'. I do not know this very well. But please first try to identify and (dis)verify the statement.
-
July 17, 2010 at 6:54 pm #31102jrwMember'peterlaursen' wrote on '17:
What is the SQlyog version? There are different ways to import from CSV-files (depending on SQLyog version). Are you using the option to use LOAD DATA syntax or the ODBC-based option?
I think from your description it is LOAD DATA and in that case you can see the SQL-statement executed by SQLyog in HISTORY tab. If you find the statement there it will likely also fail from the editor (or any other client)- Please check.
It looks very much like an issue with mapping of drive letters in 'parallels'. I do not know this very well. But please first try to identify and (dis)verify the statement.
Peter, thanks.
I am using the LOAD DATA option. I had my suspicion about the drive mapping. Having checked the History tab it is trying to load using this line.
load data local infile '\\.psf\Home\Documents\Pentathlon\MPAGB\Competitions\Results\Biathle\WeymouthWebresults2010.csv' into table `MPAGB`.`tblResultsBiathle_update` fields escaped by '\' terminated by 't' lines terminated by 'n' (`result_id`, `event_id`, `individual_id`, `age_group`, `biathle_time_mins`, `biathle_time_secs`, `biathle_points`, `ranking`);
Am I stuck or can you suggest a solution?
Thanks
John
-
July 17, 2010 at 7:24 pm #31103jrwMember
Apologies, version is 6.56.
-
July 17, 2010 at 8:37 pm #31104peterlaursenParticipant
Can you figure out a path that would work instead of '\\.psf\Home\Documents\Pentathlon\MPAGB\Competitions\Results\Biathle\WeymouthWebresults2010.csv' ?
-
July 17, 2010 at 8:59 pm #31105jrwMember
Good thinking. It doesn't matter where I put it on my pc – it wouldn't import. So I put the file on a remote server and imported from there and Bingo!
Thanks for your help.
John
-
July 18, 2010 at 7:55 am #31106peterlaursenParticipant
Maybe a OS-X/Windows system built with 'parallels' needs some special configuration in order to have one system read files from the other. Maybe somebody in office knows. Let me ask around.
The only VM I have experience with personally is Virtualbox, and here it is not very easy to share folders between the systems either. I use to work around by attaching a USB-harddrive that can be read from both systems easily.
-
July 18, 2010 at 12:18 pm #31107jrwMember
Parallels is actually pretty awesome at reading files which are held on the OS-X platform. I have the My Documents folder in Windows XP running in the Parallels VM mapped to the Documents folder in OS-X and it works fine – this is the first time I have had this problem.
What is more curious is that although I had the problem importing data from the csv file, I haven't had a problem running a .sql script (held in the same directory as the csv file) via the Tools > Restore From SQL Dump…. menu option. So SQLyog seems to be able to read the path that Parallels creates in some circumstances but not in others, which is a little strange.
-
July 18, 2010 at 3:51 pm #31108peterlaursenParticipant
We will have to check ourselves. Maybe we do not use the same code for getting the two file paths.
-
-
AuthorPosts
- You must be logged in to reply to this topic.