gaza165 Posted May 21, 2009 Share Posted May 21, 2009 Hi can someone steer me in the right direction I would like to know how to display my databases and count how many tables are in each and display them.. this is what i have. <?php include("./includes/dbconnect.php"); $sql = mysql_query("show databases"); while($row = mysql_fetch_array($sql)) { echo $row['Database']; } ?> i want something like information_schema(3) cdcol(4) mysql(2) phpmyadmin(7) test webauth Link to comment https://forums.phpfreaks.com/topic/159102-sql-show-databases-and-count-tables/ Share on other sites More sharing options...
madspof Posted May 21, 2009 Share Posted May 21, 2009 you need to use sumin like this mysql_list_dbs($conn); to list the DB's Link to comment https://forums.phpfreaks.com/topic/159102-sql-show-databases-and-count-tables/#findComment-839085 Share on other sites More sharing options...
alex clone Posted May 21, 2009 Share Posted May 21, 2009 I don't know if I am correct but shouldn't this go in the mysql help section(s)? Link to comment https://forums.phpfreaks.com/topic/159102-sql-show-databases-and-count-tables/#findComment-839102 Share on other sites More sharing options...
Recommended Posts
Archived
This topic is now archived and is closed to further replies.