diff --git a/system/database/drivers/mssql/mssql_driver.php b/system/database/drivers/mssql/mssql_driver.php
index 8b82ee3..cb2f48d 100644
--- a/system/database/drivers/mssql/mssql_driver.php
+++ b/system/database/drivers/mssql/mssql_driver.php
@@ -258,19 +258,6 @@
$row = $query->row();
return $row->numrows;
}
-
- // --------------------------------------------------------------------
-
- /**
- * List databases
- *
- * @access private
- * @return bool
- */
- function _list_databases()
- {
- return "EXEC sp_helpdb"; // Can also be: EXEC sp_databases
- }
// --------------------------------------------------------------------
diff --git a/system/database/drivers/mssql/mssql_utility.php b/system/database/drivers/mssql/mssql_utility.php
index ad13167..388dbe1 100644
--- a/system/database/drivers/mssql/mssql_utility.php
+++ b/system/database/drivers/mssql/mssql_utility.php
@@ -67,6 +67,19 @@
// --------------------------------------------------------------------
/**
+ * List databases
+ *
+ * @access private
+ * @return bool
+ */
+ function _list_databases()
+ {
+ return "EXEC sp_helpdb"; // Can also be: EXEC sp_databases
+ }
+
+ // --------------------------------------------------------------------
+
+ /**
* Optimize table query
*
* Generates a platform-specific query so that a table can be optimized
diff --git a/system/database/drivers/mysql/mysql_driver.php b/system/database/drivers/mysql/mysql_driver.php
index ecab648..253627c 100644
--- a/system/database/drivers/mysql/mysql_driver.php
+++ b/system/database/drivers/mysql/mysql_driver.php
@@ -296,19 +296,6 @@
// --------------------------------------------------------------------
/**
- * List databases
- *
- * @access private
- * @return bool
- */
- function _list_databases()
- {
- return "SHOW DATABASES";
- }
-
- // --------------------------------------------------------------------
-
- /**
* List table query
*
* Generates a platform-specific query string so that the table names can be fetched
diff --git a/system/database/drivers/mysql/mysql_utility.php b/system/database/drivers/mysql/mysql_utility.php
index a81c915..b387ace 100644
--- a/system/database/drivers/mysql/mysql_utility.php
+++ b/system/database/drivers/mysql/mysql_utility.php
@@ -53,6 +53,19 @@
// --------------------------------------------------------------------
/**
+ * List databases
+ *
+ * @access private
+ * @return bool
+ */
+ function _list_databases()
+ {
+ return "SHOW DATABASES";
+ }
+
+ // --------------------------------------------------------------------
+
+ /**
* Drop Table
*
* @access private
@@ -101,7 +114,7 @@
* MySQL Export
*
* @access private
- * @param array Any preferences
+ * @param array Preferences
* @return mixed
*/
function _backup($params = array())
@@ -217,7 +230,6 @@
// Build the INSERT string
$output .= 'INSERT INTO '.$table.' ('.$field_str.') VALUES ('.$val_str.');'.$newline;
-
}
$output .= $newline.$newline;
diff --git a/system/database/drivers/mysqli/mysqli_driver.php b/system/database/drivers/mysqli/mysqli_driver.php
index a2c3803..4fd9f3a 100644
--- a/system/database/drivers/mysqli/mysqli_driver.php
+++ b/system/database/drivers/mysqli/mysqli_driver.php
@@ -288,19 +288,6 @@
// --------------------------------------------------------------------
/**
- * List databases
- *
- * @access private
- * @return bool
- */
- function _list_databases()
- {
- return "SHOW DATABASES";
- }
-
- // --------------------------------------------------------------------
-
- /**
* List table query
*
* Generates a platform-specific query string so that the table names can be fetched
diff --git a/system/database/drivers/mysqli/mysqli_utility.php b/system/database/drivers/mysqli/mysqli_utility.php
index f5b98b1..a40441d 100644
--- a/system/database/drivers/mysqli/mysqli_utility.php
+++ b/system/database/drivers/mysqli/mysqli_utility.php
@@ -62,6 +62,19 @@
{
return "DROP TABLE IF EXISTS ".$this->db->_escape_table($name);
}
+
+ // --------------------------------------------------------------------
+
+ /**
+ * List databases
+ *
+ * @access private
+ * @return bool
+ */
+ function _list_databases()
+ {
+ return "SHOW DATABASES";
+ }
// --------------------------------------------------------------------
diff --git a/system/database/drivers/oci8/oci8_driver.php b/system/database/drivers/oci8/oci8_driver.php
index b43b4c4..e83c640 100644
--- a/system/database/drivers/oci8/oci8_driver.php
+++ b/system/database/drivers/oci8/oci8_driver.php
@@ -399,19 +399,6 @@
return $row->NUMROWS;
}
- // --------------------------------------------------------------------
-
- /**
- * List databases
- *
- * @access private
- * @return bool
- */
- function _list_databases()
- {
- return FALSE;
- }
-
// --------------------------------------------------------------------
/**
diff --git a/system/database/drivers/oci8/oci8_utility.php b/system/database/drivers/oci8/oci8_utility.php
index b6503de..b1d539a 100644
--- a/system/database/drivers/oci8/oci8_utility.php
+++ b/system/database/drivers/oci8/oci8_utility.php
@@ -54,6 +54,19 @@
// --------------------------------------------------------------------
/**
+ * List databases
+ *
+ * @access private
+ * @return bool
+ */
+ function _list_databases()
+ {
+ return FALSE;
+ }
+
+ // --------------------------------------------------------------------
+
+ /**
* Drop Table
*
* @access private
diff --git a/system/database/drivers/odbc/odbc_driver.php b/system/database/drivers/odbc/odbc_driver.php
index 0f002cc..4bd6e11 100644
--- a/system/database/drivers/odbc/odbc_driver.php
+++ b/system/database/drivers/odbc/odbc_driver.php
@@ -263,24 +263,6 @@
// --------------------------------------------------------------------
/**
- * List databases
- *
- * @access private
- * @return bool
- */
- function _list_databases()
- {
- // Not sure if ODBC lets you list all databases...
- if ($this->db_debug)
- {
- return $this->display_error('db_unsuported_feature');
- }
- return FALSE;
- }
-
- // --------------------------------------------------------------------
-
- /**
* Show table query
*
* Generates a platform-specific query string so that the table names can be fetched
diff --git a/system/database/drivers/odbc/odbc_utility.php b/system/database/drivers/odbc/odbc_utility.php
index 6d0fb79..5a0e365 100644
--- a/system/database/drivers/odbc/odbc_utility.php
+++ b/system/database/drivers/odbc/odbc_utility.php
@@ -66,6 +66,24 @@
// --------------------------------------------------------------------
/**
+ * List databases
+ *
+ * @access private
+ * @return bool
+ */
+ function _list_databases()
+ {
+ // Not sure if ODBC lets you list all databases...
+ if ($this->db->db_debug)
+ {
+ return $this->db->display_error('db_unsuported_feature');
+ }
+ return FALSE;
+ }
+
+ // --------------------------------------------------------------------
+
+ /**
* Drop Table
*
* @access private
diff --git a/system/database/drivers/postgre/postgre_driver.php b/system/database/drivers/postgre/postgre_driver.php
index f143956..340d650 100644
--- a/system/database/drivers/postgre/postgre_driver.php
+++ b/system/database/drivers/postgre/postgre_driver.php
@@ -290,19 +290,6 @@
// --------------------------------------------------------------------
/**
- * List databases
- *
- * @access private
- * @return bool
- */
- function _list_databases()
- {
- return "SELECT datname FROM pg_database";
- }
-
- // --------------------------------------------------------------------
-
- /**
* Show table query
*
* Generates a platform-specific query string so that the table names can be fetched
diff --git a/system/database/drivers/postgre/postgre_utility.php b/system/database/drivers/postgre/postgre_utility.php
index 46c98cc..038aa26 100644
--- a/system/database/drivers/postgre/postgre_utility.php
+++ b/system/database/drivers/postgre/postgre_utility.php
@@ -54,6 +54,19 @@
// --------------------------------------------------------------------
/**
+ * List databases
+ *
+ * @access private
+ * @return bool
+ */
+ function _list_databases()
+ {
+ return "SELECT datname FROM pg_database";
+ }
+
+ // --------------------------------------------------------------------
+
+ /**
* Drop Table
*
* @access private
diff --git a/system/database/drivers/sqlite/sqlite_driver.php b/system/database/drivers/sqlite/sqlite_driver.php
index f57c4b8..9da50b6 100644
--- a/system/database/drivers/sqlite/sqlite_driver.php
+++ b/system/database/drivers/sqlite/sqlite_driver.php
@@ -282,28 +282,6 @@
// --------------------------------------------------------------------
/**
- * List databases
- *
- * I don't believe you can do a database listing with SQLite
- * since each database is its own file. I suppose we could
- * try reading a directory looking for SQLite files, but
- * that doesn't seem like a terribly good idea
- *
- * @access private
- * @return bool
- */
- function _list_databases()
- {
- if ($this->db_debug)
- {
- return $this->display_error('db_unsuported_feature');
- }
- return array();
- }
-
- // --------------------------------------------------------------------
-
- /**
* List table query
*
* Generates a platform-specific query string so that the table names can be fetched
diff --git a/system/database/drivers/sqlite/sqlite_utility.php b/system/database/drivers/sqlite/sqlite_utility.php
index 801660d..19b06bd 100644
--- a/system/database/drivers/sqlite/sqlite_utility.php
+++ b/system/database/drivers/sqlite/sqlite_utility.php
@@ -64,6 +64,28 @@
// --------------------------------------------------------------------
/**
+ * List databases
+ *
+ * I don't believe you can do a database listing with SQLite
+ * since each database is its own file. I suppose we could
+ * try reading a directory looking for SQLite files, but
+ * that doesn't seem like a terribly good idea
+ *
+ * @access private
+ * @return bool
+ */
+ function _list_databases()
+ {
+ if ($this->db_debug)
+ {
+ return $this->display_error('db_unsuported_feature');
+ }
+ return array();
+ }
+
+ // --------------------------------------------------------------------
+
+ /**
* Drop Table
*
* Unsupported feature in SQLite