-
Incident report
-
Resolution: Unresolved
-
Trivial
-
None
-
2.2.1
If you're trying to import templates to oracle database, you will receive an error
• SQL error [ORA-00932: inconsistent datatypes: expected - got CLOB] in [SELECT DISTINCT t.* FROM triggers t,functions f,items i WHERE i.hostid='17573' AND f.itemid=i.itemid AND f.triggerid=t.triggerid]
to fix this issue we have next patch:
--- ./include/triggers.inc_orig.php 2013-12-27 14:32:04.264833539 +0000 +++ ./include/triggers.inc.php 2013-12-27 14:42:45.277729342 +0000 @@ -287,7 +287,7 @@ function get_triggers_by_hostid($hostid) { return DBselect( - 'SELECT DISTINCT t.*'. + 'SELECT DISTINCT t.TRIGGERID,t.EXPRESSION,t.DESCRIPTION,t.URL,t.STATUS,t.VALUE,t.PRIORITY,t.LASTCHANGE,t.ERROR,t.TEMPLATEID,t.TYPE,t.STATE,t.FLAGS'. ' FROM triggers t,functions f,items i'. ' WHERE i.hostid='.zbx_dbstr($hostid). ' AND f.itemid=i.itemid'.
We should use all row except CLOB type.
example of row is:
COMMENTS CLOB