summaryrefslogtreecommitdiffstats
path: root/system/database/drivers/pdo/subdrivers/pdo_oci_driver.php
diff options
context:
space:
mode:
authorAndrey Andreev <narf@bofh.bg>2012-07-19 12:06:02 +0200
committerAndrey Andreev <narf@bofh.bg>2012-07-19 12:06:02 +0200
commitc9b924c1498847d8f324d81c8994fff0b95f26dc (patch)
treec78ca7d7ad67df0cf69414180e36a037c8c45970 /system/database/drivers/pdo/subdrivers/pdo_oci_driver.php
parent94611df88cf99ae530258a25e2051e901b9ffcc7 (diff)
Remove _limit()'s extra parameters and qb_limit, qb_offset unneeded typecasts + add _compile_group_by() method
Diffstat (limited to 'system/database/drivers/pdo/subdrivers/pdo_oci_driver.php')
-rw-r--r--system/database/drivers/pdo/subdrivers/pdo_oci_driver.php10
1 files changed, 4 insertions, 6 deletions
diff --git a/system/database/drivers/pdo/subdrivers/pdo_oci_driver.php b/system/database/drivers/pdo/subdrivers/pdo_oci_driver.php
index 494d82c3f..cfbb639a8 100644
--- a/system/database/drivers/pdo/subdrivers/pdo_oci_driver.php
+++ b/system/database/drivers/pdo/subdrivers/pdo_oci_driver.php
@@ -196,7 +196,7 @@ class CI_DB_pdo_oci_driver extends CI_DB_pdo_driver {
{
if ($this->qb_limit)
{
- $this->where('rownum <= ', (int) $this->qb_limit, FALSE);
+ $this->where('rownum <= ',$this->qb_limit, FALSE);
$this->qb_limit = FALSE;
}
@@ -211,14 +211,12 @@ class CI_DB_pdo_oci_driver extends CI_DB_pdo_driver {
* Generates a platform-specific LIMIT clause
*
* @param string the sql query string
- * @param int the number of rows to limit the query to
- * @param int the offset value
* @return string
*/
- protected function _limit($sql, $limit, $offset)
+ protected function _limit($sql)
{
- return 'SELECT * FROM (SELECT inner_query.*, rownum rnum FROM ('.$sql.') inner_query WHERE rownum < '.($offset + $limit + 1).')'
- .($offset ? ' WHERE rnum >= '.($offset + 1): '');
+ return 'SELECT * FROM (SELECT inner_query.*, rownum rnum FROM ('.$sql.') inner_query WHERE rownum < '.($this->qb_offset + $this->qb_limit + 1).')'
+ .($this->qb_offset ? ' WHERE rnum >= '.($this->qb_offset + 1): '');
}
}