Ad Widget

Collapse

PATCH : query in Events

Collapse
X
 
  • Time
  • Show
Clear All
new posts
  • SLMitch
    Member
    • May 2006
    • 39

    #1

    PATCH : query in Events

    they are a little bug in /include/events.inc.php : hosts_groups jointure is forgotten in the SQL query.

    Code:
    --- events.inc.php-orig 2006-08-09 15:53:42.000000000 +0200
    +++ events.inc.php      2006-08-09 15:54:53.000000000 +0200
    @@ -28,7 +28,7 @@
                    }
                    elseif($groupid > 0)
                    {
    -                       $sql="select distinct a.clock,a.value,a.triggerid from alarms a,functions f,items i where a.triggerid=f.triggerid and f.itemid=i.itemid and i.hostid=hg.hostid and hg.groupid=".$groupid." order by clock desc";
    +                       $sql="select distinct a.clock,a.value,a.triggerid from alarms a,functions f,items i,hosts_groups hg where a.triggerid=f.triggerid and f.itemid=i.itemid and i.hostid=hg.hostid and hg.groupid=".$groupid." order by clock desc";
                    }
                    else
                    {
  • James Wells
    Senior Member
    • Jun 2005
    • 664

    #2
    Greetings,

    Was wondering why that was failing. I have added this to a patch I am building for submission to CVS for 1.1.3.
    Unofficial Zabbix Developer

    Comment

    • James Wells
      Senior Member
      • Jun 2005
      • 664

      #3
      This has now been submitted to CVS
      Unofficial Zabbix Developer

      Comment

      Working...