--- ./src/zabbix_server/housekeeper/housekeeper.c.orig 2009-12-21 15:57:18.000000000 +0100 +++ ./src/zabbix_server/housekeeper/housekeeper.c 2009-12-21 15:58:22.000000000 +0100 @@ -68,8 +68,7 @@ static int housekeeping_process_log() housekeeper.field, housekeeper.value); #elif defined(HAVE_POSTGRESQL) - deleted = DBexecute("delete from %s where oid in (select oid from %s where %s=" ZBX_FS_UI64 " limit 500)", - housekeeper.tablename, + deleted = DBexecute("delete from %s where %s=" ZBX_FS_UI64, housekeeper.tablename, housekeeper.field, housekeeper.value);