Oracle 5.0 Reference Manual page 2272

Table of Contents

Advertisement

See Also
mysql_query
mysql_num_rows
mysql_fetch_row
mysql_fetch_assoc
mysql_fetch_array
mysql_fetch_object
20.7.2.5.7.
mysql_db_name
Copyright 1997-2012 the PHP Documentation Group. [2230]
mysql_db_name
Retrieves database name from the call to
Description
string mysql_db_name(
resource result,
int row,
mixed field
=
Retrieve the database name from a call to mysql_list_dbs.
Parameters
result
row
field
Return Values
Returns the database name on success, and
mysql_error
Changelog
Version
5.5.0
Examples
Example 20.32.
<?php
error_reporting(E_ALL);
Original MySQL API (Mysql)
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:
Query:
SELECT DATABASE()
=NULL);
to determine the nature of the error.
mysql_db_name
mysql_list_dbs
MySQLi
or
PDO_MySQL
guide and
The result pointer from a call to mysql_list_dbs.
The index into the result set.
The field name.
on failure. If
FALSE
Description
The
mysql_list_dbs
and emits an
example
2252
extension should be used. See
related FAQ
for more information.
is returned, use
FALSE
function is deprecated,
E_DEPRECATED
level error.

Advertisement

Table of Contents
loading

This manual is also suitable for:

Mysql 5.0

Table of Contents