RE: [PHP-DB] [Import text file]
| From: | Hutchins, Richard | Date: | Thu, 13 Feb 2003 13:11:19 +0000 |
| Subject: | RE: [PHP-DB] [Import text file] | ||
| Groups: | php.db | ||
| Request: | Send a blank email to php-db+get-25602@lists.php.net to get a copy of this message | ||
A quick trip through the MySQL manual hints that you may have to use forward
slashes in your path on a windows system. So...
LOAD DATA LOCAL INFILE 'C:/WINDOWS/TEMP/phpC255.TMP' INTO TABLE
abonnes FIELDS TERMINATED BY ';' ESCAPED BY '\\' LINES TERMINATED BY
'\r\n' (dp_indpri,dp_nom,dp_ville)
...might just do the trick (note the forward slashes in the path to the
file).
Hope this helps.
> -----Original Message-----
> From: RG [mailto:rg@infogere.com]
> Sent: Wednesday, February 12, 2003 6:32 PM
> To: php-db@lists.php.net
> Subject: [PHP-DB] [Import text file]
>
>
> Hi
>
> I try to do an import text file into a mysql table with the php
> script provided with Manucorp Easyphp, but it does not work.
>
> The message is :
>
> <<Erreur
> requete SQL:
>
> LOAD DATA LOCAL INFILE 'C:\WINDOWS\TEMP\phpC255.TMP' INTO TABLE
> abonnes FIELDS TERMINATED BY ';' ESCAPED BY '\\' LINES TERMINATED BY
> '\r\n' (dp_indpri,dp_nom,dp_ville)
> MySQL a repondu:File 'c:windowstempphpc255.tmp' not found
> (Errcode:2)>>
>
> The path above seems to be incorrect, but i have not found where to
> modify it.
>
>
> Environment is :
>
> Apache 1.3.17 win32
> PHP 4.0.5-dev
> MySQL client API version 3.23.32
>
> An idea ??
> RG
> rg@infogere.com
>
>
> --
> PHP Database Mailing List (http://www.php.net/)
> To unsubscribe, visit: http://www.php.net/unsub.php
>