Oracle 5.0 Reference Manual page 2276

Table of Contents

Advertisement

Notes
See Also
mysql_query
20.7.2.5.10.
mysql_errno
Copyright 1997-2012 the PHP Documentation Group. [2230]
mysql_errno
Returns the numerical value of the error message from previous MySQL operation
Description
int mysql_errno(
resource link_identifier
=
Returns the error number from the last MySQL function.
Errors coming back from the MySQL database backend no longer issue warnings. Instead, use
mysql_errno
most recently executed MySQL function (not including
want to use it, make sure you check the value before calling another MySQL function.
Parameters
link_identifier
Return Values
Returns the error number from the last MySQL function, or
Examples
Original MySQL API (Mysql)
Warning
This function will not be available if the MySQL extension was built against a
MySQL 4.x client library.
Note
For backward compatibility, the following deprecated alias may be used:
mysql_dropdb
Warning
This extension is deprecated as of PHP 5.5.0, and will be removed in the
future. Instead, the
also
MySQL: choosing an API
Alternatives to this function include:
mysqli_errno
PDO::errorCode
=NULL);
to retrieve the error code. Note that this function only returns the error code from the
MySQLi
or
PDO_MySQL
guide and
mysql_error
The MySQL connection. If the link identifier is not specified, the
last link opened by
mysql_connect
is found, it will try to create one as if
with no arguments. If no connection is found or established, an
level error is generated.
E_WARNING
2256
extension should be used. See
related FAQ
for more information.
and mysql_errno), so if you
is assumed. If no such link
mysql_connect
(zero) if no error occurred.
0
was called

Advertisement

Table of Contents
loading

This manual is also suitable for:

Mysql 5.0

Table of Contents