diff options
author | osmiy <osmiy@97f52cf1-0a1b-0410-bd0e-c28be96e8082> | 2006-05-19 09:18:27 +0000 |
---|---|---|
committer | osmiy <osmiy@97f52cf1-0a1b-0410-bd0e-c28be96e8082> | 2006-05-19 09:18:27 +0000 |
commit | 55258ec574e3e9a0984b13cf119d725dd8ae1791 (patch) | |
tree | bbb37fe8a5d51d7eb363989108becaa5399bcd8d /frontends/php/history.php | |
parent | 1c3253c2dddc63349e34e38d681bedeede2da8a7 (diff) | |
download | zabbix-55258ec574e3e9a0984b13cf119d725dd8ae1791.tar.gz zabbix-55258ec574e3e9a0984b13cf119d725dd8ae1791.tar.xz zabbix-55258ec574e3e9a0984b13cf119d725dd8ae1791.zip |
- fixed oracle sql request limitation
git-svn-id: svn://svn.zabbix.com/trunk@2859 97f52cf1-0a1b-0410-bd0e-c28be96e8082
Diffstat (limited to 'frontends/php/history.php')
-rw-r--r-- | frontends/php/history.php | 12 |
1 files changed, 6 insertions, 6 deletions
diff --git a/frontends/php/history.php b/frontends/php/history.php index 38b4106e..aafab46b 100644 --- a/frontends/php/history.php +++ b/frontends/php/history.php @@ -295,9 +295,9 @@ } $cond_clock = ""; - $cond_limit = ""; + $limit = "NO"; if($_REQUEST["action"]=="showlatest"){ - $cond_limit = " limit 500"; + $limit = 500; } elseif($_REQUEST["action"]=="showvalues"){ $cond_clock = " and h.clock>$time and h.clock<$till"; } @@ -332,9 +332,9 @@ $sql = "select hst.host,i.itemid,i.key_,i.description,h.clock,h.value,i.valuemapid,h.timestamp,h.source,h.severity". " from history_log h, items i, hosts hst". " where hst.hostid=i.hostid and h.itemid=i.itemid".$sql_filter." and i.itemid in (".$itemid_lst.")".$cond_clock. - " order by clock desc".$cond_limit; + " order by clock desc"; - $result=DBselect($sql); + $result=DBselect($sql,$limit); if(!isset($_REQUEST["plaintext"])) { @@ -457,8 +457,8 @@ $sql = "select h.clock,h.value,i.valuemapid from $h_table h, items i". " where h.itemid=i.itemid and i.itemid=".$_REQUEST["itemid"]. - $cond_clock." order by clock desc".$cond_limit; - $result=DBselect($sql); + $cond_clock." order by clock desc"; + $result=DBselect($sql, $limit); if(!isset($_REQUEST["plaintext"])) { $table = new CTableInfo(); |