when I type:
LOAD DATA LOCAL INFILE '/home/db/file.txt' INTO TABLE table fields optionally enclosed by '\"'";
at the mysql prompt (on a Linux server), I have no problems whatsoever.
When I try the script:
<?php
/*assume here I am connected to the correct database - I have checked!*/
$sql="LOAD DATA LOCAL INFILE '/home/db/file.txt' INTO TABLE table fields optionally enclosed by '\"'";
if($result=mysql_query($sql)){echo"success";}
?>
I get "success" output, but no data in the table.
I have checked the text file scrupulously - nothing wrong with it.
Why is it not working?
Anybody?
LOAD DATA LOCAL INFILE '/home/db/file.txt' INTO TABLE table fields optionally enclosed by '\"'";
at the mysql prompt (on a Linux server), I have no problems whatsoever.
When I try the script:
<?php
/*assume here I am connected to the correct database - I have checked!*/
$sql="LOAD DATA LOCAL INFILE '/home/db/file.txt' INTO TABLE table fields optionally enclosed by '\"'";
if($result=mysql_query($sql)){echo"success";}
?>
I get "success" output, but no data in the table.
I have checked the text file scrupulously - nothing wrong with it.
Why is it not working?
Anybody?