Helpful Information
 
 
Category: Programming Languages
php and mysql

I have the problem with this statements

$sql="load data infile '/home/mhd/testing/htdocs/iscritto.txt' into table
$tabella fields terminated by ';'
optionally enclosed by '"' escaped by ''
(codice_u, codice_b)";

if (!($result=mysql_query($sql, $conn)))
{echo "errore nella query";};

This risult print always "error on the query"
Why?

Try using mysql_error() to get more info on what's wrong with the query.

Like this:



$result = mysql_query($sql, $conn) or die(mysql_error());

Originally posted by Jobbe
Try using mysql_error() to get more info on what's wrong with the query.

Like this:



$result = mysql_query($sql, $conn) or die(mysql_error());

Jobbe,

Her post is from over 4 years ago... I'm sure she's figured out the issue w/ this error by now.

- DrGroove

lmao










privacy (GDPR)