-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

Ahmed S K Anis wrote:
Yes Mark it worked from the command line.

The Archived resides at the server side. I ran Load data local infile 'sys:\\mail\\dump.txt" into table X it worked.

The from a different machine i ran this java program. The Archived
file still exists at the DB server side.
So i guess local option is not necessary. It didnt work though I guess the path it takes is wrong.

String filepath = "sys:\\restore\\data1.txt";
String query = "load data local infile \'" + filepath + "\' into table
x

it takes as estoredata1.txt as file name not clear why ?
Because '\\' in Java is the escape code for a _single '\' :)

You need \\\\ to get \\ in String literals.

What your String actually ends up being is sys:\restore\data1.txt, and '\' also has special meaning in MySQL.

-Mark



- -- MySQL 2003 Users Conference -> http://www.mysql.com/events/uc2003/

For technical support contracts, visit https://order.mysql.com/?ref=mmma

__ ___ ___ ____ __
/ |/ /_ __/ __/ __ \/ / Mark Matthews <[EMAIL PROTECTED]>
/ /|_/ / // /\ \/ /_/ / /__ MySQL AB, Full-Time Developer - JDBC/Java
/_/ /_/\_, /___/\___\_\___/ Flossmoor (Chicago), IL USA
<___/ www.mysql.com
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.1.90 (MingW32)
Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org

iD8DBQE+Sl0btvXNTca6JD8RAmptAKCqDXC/l8YnSqemI5YbHVhlaC187wCfVzRG
OPROaY07+yKvKHHjuwy7uEU=
=V70Y
-----END PGP SIGNATURE-----


---------------------------------------------------------------------
Before posting, please check:
http://www.mysql.com/manual.php (the manual)
http://lists.mysql.com/ (the list archive)

To request this thread, e-mail <[EMAIL PROTECTED]>
To unsubscribe, e-mail <[EMAIL PROTECTED]>
Trouble unsubscribing? Try: http://lists.mysql.com/php/unsubscribe.php



Reply via email to