From ea6bdbcf952e5ac4696cb91364c1923f6ab96321 Mon Sep 17 00:00:00 2001 From: osmiy Date: Mon, 8 Jan 2007 16:13:49 +0000 Subject: - improved databases determination of configuration script (Eugene) git-svn-id: svn://svn.zabbix.com/trunk@3664 97f52cf1-0a1b-0410-bd0e-c28be96e8082 --- src/zabbix_server/timer/Makefile.am | 2 +- src/zabbix_server/timer/timer.c | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) (limited to 'src/zabbix_server/timer') diff --git a/src/zabbix_server/timer/Makefile.am b/src/zabbix_server/timer/Makefile.am index 1a9efcc2..338d5e3a 100644 --- a/src/zabbix_server/timer/Makefile.am +++ b/src/zabbix_server/timer/Makefile.am @@ -1,4 +1,4 @@ SUBDIRS= -INCLUDES=-I@top_srcdir@/include @MYSQL_INCLUDE@ @ORACLE_INCLUDE@ @PGSQL_INCLUDE@ +INCLUDES=-I@top_srcdir@/include @MYSQL_CFLAGS@ @ORACLE_INCLUDE@ @POSTGRESQL_CFLAGS@ lib_LIBRARIES=libzbxtimer.a libzbxtimer_a_SOURCES=timer.c diff --git a/src/zabbix_server/timer/timer.c b/src/zabbix_server/timer/timer.c index 6a08fbb6..a5ff96db 100644 --- a/src/zabbix_server/timer/timer.c +++ b/src/zabbix_server/timer/timer.c @@ -83,7 +83,7 @@ void main_timer_loop() now=time(NULL); /* -#ifdef HAVE_PGSQL +#ifdef HAVE_POSTGRESQL zbx_snprintf(sql,sizeof(sql),"select distinct f.itemid,f.functionid,f.parameter from functions f, items i,hosts h where h.hostid=i.hostid and h.status=%d and i.itemid=f.itemid and f.function in ('nodata','date','dayofweek','time','now') and i.lastclock+f.parameter::text::integer<=%d and i.status=%d", HOST_STATUS_MONITORED, now, ITEM_STATUS_ACTIVE); #else zbx_snprintf(sql,sizeof(sql),"select distinct f.itemid,f.functionid,f.parameter,f.function from functions f, items i,hosts h where h.hostid=i.hostid and h.status=%d and i.itemid=f.itemid and f.function in ('nodata','date','dayofweek','time','now') and i.lastclock+f.parameter<=%d and i.status=%d", HOST_STATUS_MONITORED, now, ITEM_STATUS_ACTIVE); -- cgit