php.net |  support |  documentation |  report a bug |  advanced search |  search howto |  statistics |  random bug |  login
Bug #1675 Wrong value returned
Submitted: 1999-07-07 05:20 UTC Modified: 1999-07-07 05:33 UTC
From: tite at mrbit dot es Assigned:
Status: Closed Package: MySQL related
PHP Version: 3.0.9 OS: Linux - SuSe 5.3
Private report: No CVE-ID: None
Welcome back! If you're the original bug submitter, here's where you can edit the bug or add additional notes.
If you forgot your password, you can retrieve your password here.
Password:
Status:
Package:
Bug Type:
Summary:
From: tite at mrbit dot es
New email:
PHP Version: OS:

 

 [1999-07-07 05:20 UTC] tite at mrbit dot es
in my php code i have:
echo "<B>Numero de Base de Datos</B> : ".mysql_list_dbs($sql)."<BR>"; # ERROR                                     
echo "<B>Numero de Tablas en ifrprueba</B> : ".mysql_list_tables("ifrprueba",$sql)."<BR>"; #ERROR  

ifrprueba is a database that exists. The result of these funcions are:

Numero de Base de Datos : 5
Numero de Tablas en ifrprueba : 6

The point is that there are not 5 Databases, but 3. And there are not 6 tables in that database but 1.

bbs:/usr/local/bin # ./mysqlshow -u ifr -p              
Enter password: 
+-----------+
| Databases |
+-----------+
| ifrprueba |
| mysql     |
| test      |
+-----------+
bbs:/usr/local/bin # ./mysqlshow -u ifr -p ifrprueba
Enter password: 
Database: ifrprueba
+--------+
| Tables |
+--------+
| test   |
+--------+

Thank You.

Josafat Moragrega

Patches

Pull Requests

History

AllCommentsChangesGit/SVN commitsRelated reports
 [1999-07-07 05:33 UTC] sas at cvs dot php dot net
Have a look at the documentation. These functions return the _id_ to a normal result set, not the actual number of entries.
 
PHP Copyright © 2001-2025 The PHP Group
All rights reserved.
Last updated: Tue Jun 03 09:01:26 2025 UTC