diff options
Diffstat (limited to 'system/database/drivers')
4 files changed, 5 insertions, 3 deletions
diff --git a/system/database/drivers/pdo/subdrivers/pdo_sqlite_driver.php b/system/database/drivers/pdo/subdrivers/pdo_sqlite_driver.php index d5ca741fd..409e6501b 100644 --- a/system/database/drivers/pdo/subdrivers/pdo_sqlite_driver.php +++ b/system/database/drivers/pdo/subdrivers/pdo_sqlite_driver.php @@ -140,7 +140,7 @@ class CI_DB_pdo_sqlite_driver extends CI_DB_pdo_driver { } $this->data_cache['field_names'][$table] = array(); - foreach ($result as $row) + foreach ($result->result_array() as $row) { $this->data_cache['field_names'][$table][] = $row['name']; } diff --git a/system/database/drivers/pdo/subdrivers/pdo_sqlite_forge.php b/system/database/drivers/pdo/subdrivers/pdo_sqlite_forge.php index 28faaddb7..15afbdef5 100644 --- a/system/database/drivers/pdo/subdrivers/pdo_sqlite_forge.php +++ b/system/database/drivers/pdo/subdrivers/pdo_sqlite_forge.php @@ -89,6 +89,7 @@ class CI_DB_pdo_sqlite_forge extends CI_DB_pdo_forge { if (version_compare($this->db->version(), '3.3', '<')) { $this->_create_table_if = FALSE; + $this->_drop_table_if = FALSE; } } diff --git a/system/database/drivers/sqlite3/sqlite3_driver.php b/system/database/drivers/sqlite3/sqlite3_driver.php index a7c6420bb..31e37de91 100644 --- a/system/database/drivers/sqlite3/sqlite3_driver.php +++ b/system/database/drivers/sqlite3/sqlite3_driver.php @@ -266,7 +266,7 @@ class CI_DB_sqlite3_driver extends CI_DB { } $this->data_cache['field_names'][$table] = array(); - foreach ($result as $row) + foreach ($result->result_array() as $row) { $this->data_cache['field_names'][$table][] = $row['name']; } diff --git a/system/database/drivers/sqlite3/sqlite3_forge.php b/system/database/drivers/sqlite3/sqlite3_forge.php index 69f65b6f3..24690ba20 100644 --- a/system/database/drivers/sqlite3/sqlite3_forge.php +++ b/system/database/drivers/sqlite3/sqlite3_forge.php @@ -74,7 +74,8 @@ class CI_DB_sqlite3_forge extends CI_DB_forge { if (version_compare($this->db->version(), '3.3', '<')) { - $this->create_table_if = FALSE; + $this->_create_table_if = FALSE; + $this->_drop_table_if = FALSE; } } |