in reply to Re^2: Unable to load entire CSV file into DB
in thread Unable to load entire CSV file into DB
I expect the file format will be the issue, quite possibly the line endings. The first simple thing in your upload is to do this:
$buffer =~ s/[\r\n]+/\n/g;
to standardise all your line endings. You could use \r if you want but \n is the default, the standard .... and it's less typing in your LOAD DATA.
If that does not work then I suggest you use perl to read and validate the uploaded file before you pass it to mysql. I too suggest trying to load the file manually. You could download the file and try loading it into a local MySQL DB if you don't have access to the remote one.
cheers
tachyon
|
---|
Replies are listed 'Best First'. | |
---|---|
Re^4: Unable to load entire CSV file into DB
by bradcathey (Prior) on Nov 07, 2004 at 12:46 UTC | |
by steves (Curate) on Nov 07, 2004 at 13:10 UTC | |
by bradcathey (Prior) on Nov 08, 2004 at 00:02 UTC |