Start of MySQL Backup structure method

This commit is contained in:
Timothy Warren 2012-05-15 13:08:35 -04:00
parent f555b179b4
commit fd4a9e1587

View File

@ -129,12 +129,20 @@ class MySQL_Util extends DB_Util {
// Get databases // Get databases
$dbs = $this->conn->get_dbs(); $dbs = $this->conn->get_dbs();
foreach($dbs as $d) foreach($dbs as &$d)
{ {
// Get the list of tables // Get the list of tables
$tables = $this->conn->driver_query("SHOW TABLES FROM `{$database}`");
// Get the sql for the table // Get the list of views
$query = $this->conn->query("SHOW CREATE TABLE {$table}"); $views = $this->conn->driver_query("SHOW VIEWS FROM `{$database}`");
$tav = array_merge($tabes,$views);
foreach($tav as &$table)
{
$string = $this->conn->driver_query("SHOW CREATE TABLE {$table}");
}
} }