From: Antoine Musso Date: Tue, 9 Aug 2005 10:37:37 +0000 (+0000) Subject: I really meant 3 parameters as kate made it in ORACLE stuff. X-Git-Tag: 1.6.0~2042 X-Git-Url: http://git.cyclocoop.org/%7B%24admin_url%7Dcompta/comptes/journal.php?a=commitdiff_plain;h=9d19c185d3733848b56879de67f633016a5499a1;p=lhc%2Fweb%2Fwiklou.git I really meant 3 parameters as kate made it in ORACLE stuff. --- diff --git a/includes/Database.php b/includes/Database.php index 6422057962..8d1e37da61 100644 --- a/includes/Database.php +++ b/includes/Database.php @@ -1277,12 +1277,15 @@ class Database { /** * Construct a LIMIT query with optional offset * This is used for query pages + * $sql string SQL query we will append the limit too + * $limit integer the SQL limit + * $offset integer the SQL offset (default false) */ - function limitResult($limit, $offset=false) { - return " LIMIT ".((is_numeric($offset) && $offset != 0)?"{$offset},":"")."{$limit} "; + function limitResult($sql, $limit, $offset=false) { + return " $sql LIMIT ".((is_numeric($offset) && $offset != 0)?"{$offset},":"")."{$limit} "; } - function limitResultForUpdate($num) { - return $this->limitResult($num, 0); + function limitResultForUpdate($sql, $num) { + return $this->limitResult($sql, $num, 0); } /**