summaryrefslogtreecommitdiffstats
path: root/system/database/DB_driver.php
diff options
context:
space:
mode:
Diffstat (limited to 'system/database/DB_driver.php')
-rw-r--r--system/database/DB_driver.php12
1 files changed, 5 insertions, 7 deletions
diff --git a/system/database/DB_driver.php b/system/database/DB_driver.php
index 271a70ec4..7309326e2 100644
--- a/system/database/DB_driver.php
+++ b/system/database/DB_driver.php
@@ -395,23 +395,21 @@ class CI_DB_driver {
}
// Load and instantiate the result driver
-
$driver = $this->load_rdriver();
$RES = new $driver();
$RES->conn_id = $this->conn_id;
$RES->result_id = $this->result_id;
- if ($this->dbdriver == 'oci8')
+ if ($this->dbdriver === 'oci8')
{
$RES->stmt_id = $this->stmt_id;
- $RES->curs_id = NULL;
+ $RES->curs_id = $this->curs_id;
$RES->limit_used = $this->limit_used;
+ // Passing the next one by reference to make sure it's updated, if needed:
+ $RES->commit_mode = &$this->_commit;
$this->stmt_id = FALSE;
}
- // oci8 vars must be set before calling this
- $RES->num_rows = $RES->num_rows();
-
// Is query caching enabled? If so, we'll serialize the
// result object and save it to a cache file.
if ($this->cache_on == TRUE AND $this->_cache_init())
@@ -423,9 +421,9 @@ class CI_DB_driver {
// result object, so we'll have to compile the data
// and save it)
$CR = new CI_DB_result();
- $CR->num_rows = $RES->num_rows();
$CR->result_object = $RES->result_object();
$CR->result_array = $RES->result_array();
+ $CR->num_rows = $RES->num_rows();
// Reset these since cached objects can not utilize resource IDs.
$CR->conn_id = NULL;