summaryrefslogtreecommitdiffstats
path: root/include
diff options
context:
space:
mode:
authorhugetoad <hugetoad@97f52cf1-0a1b-0410-bd0e-c28be96e8082>2004-02-08 20:31:07 +0000
committerhugetoad <hugetoad@97f52cf1-0a1b-0410-bd0e-c28be96e8082>2004-02-08 20:31:07 +0000
commit5ad9a7a76d255d3cf47f8b678433efcbb9e57134 (patch)
tree073a6a52fc03d8cb6ec5db17227a1cc87d14dd67 /include
parent88e356bd3c51be5db7f7bafdc6b0acaedcc68182 (diff)
- changed DB schema. Dropped foreign key for table actions (Alexei)
git-svn-id: svn://svn.zabbix.com/trunk@1247 97f52cf1-0a1b-0410-bd0e-c28be96e8082
Diffstat (limited to 'include')
-rw-r--r--include/functions.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/include/functions.c b/include/functions.c
index 7a6f727e..e0d30a52 100644
--- a/include/functions.c
+++ b/include/functions.c
@@ -941,7 +941,7 @@ void apply_actions(DB_TRIGGER *trigger,int trigger_value)
{
continue;
}
- snprintf(sql,sizeof(sql)-1,"select * from actions a,triggers t,hosts h,functions f,items i where a.triggerid=t.triggerid and f.triggerid=t.triggerid and i.itemid=f.itemid and h.hostid=i.hostid and t.triggerid=%d and a.scope=%d",trigger->triggerid,ACTION_SCOPE_HOST);
+ snprintf(sql,sizeof(sql)-1,"select * from actions a,triggers t,hosts h,functions f where a.triggerid=t.triggerid and f.triggerid=t.triggerid and h.hostid=a.triggerid and t.triggerid=%d and a.scope=%d",trigger->triggerid,ACTION_SCOPE_HOST);
/* zabbix_log( LOG_LEVEL_WARNING, "[%s]",sql);*/
result2 = DBselect(sql);
if(DBnum_rows(result2)==0)