Longren" <[EMAIL PROTECTED]>; <[EMAIL PROTECTED]>
Sent: Wednesday, August 06, 2003 3:35 PM
Subject: Re: [PHP] mysql_error() problem?
> From: "Tyler Longren" <[EMAIL PROTECTED]>
> > I'm running an UPDATE query on my table. After executing th
From: "Tyler Longren" <[EMAIL PROTECTED]>
> I'm running an UPDATE query on my table. After executing the query, I
check
> mysql_error() to see if there's any errors:
> if (mysql_error() == "") {
> // success
> }
> else {
> // failure
> }
>
> mysql_error() is always empty even if the query
* Thus wrote Tyler Longren ([EMAIL PROTECTED]):
> hmmm...perhaps that was it. When I had this issue before, someone told me
> to check mysql_affected_rows() when using issuing an UPDATE query. I'll
> give that a shot.
Correct, mysql_affected_rows() on a query that doesn't return rows
(insert, up
Hi,
I'm running an UPDATE query on my table. After executing the query, I check
mysql_error() to see if there's any errors:
if (mysql_error() == "") {
// success
}
else {
// failure
}
mysql_error() is always empty even if the query didn't succeed. So it
always thinks it succeeds. I rem
I am using the below function (error_db) witch is called thus:-
function query_db( $sql, $db ) {
$result = mysql_query( $sql, $db ) or
error_db( $sql, $db );
return $result;
}
But $sqlerr is always blank (it is set with '$sqlerr = mysql_error( $db
);'). Any idea why?
Ben
f
5 matches
Mail list logo