Query Agent will throw null pointer exception while executing a query with bind variable.
book
Article ID: KB0085595
calendar_today
Updated On:
Products
Versions
TIBCO BusinessEvents Enterprise Edition
-
Not Applicable
-
Description
Resolution: Description: =========== Query Agent will throw NullPointException while executing a query with bind variable.
Environment: =========== TIBCO BusinessEvents 3.0.1 All Operating Systems
Symptoms: ========= Query Agent throws the following null pointer exception if you use bind variable in WHERE clause of the query. This only happens when there are multiple conditions in the WHERE clause of the query.
>>>>>>>>>>>>>>>>>>>>>>>>>>>> 2010 Jan 29 11:59:30:601 GMT -5 <EngineName> Error [SnapshotQueryManager-1] - [BusinessEvents Archive] Got runtime exception while evaluating Rule agent1:14130293:1:join_00022: Rule Condition com.tibco.cep.query.stream.impl.rete.join.CustomEqualsCondition@2cf63 Objects <Id: com.tibco.cep.query.stream.impl.rete.ReteEntityId@1f, Timestamp: 1264784370585. [Key: 31, Source: com. tibco.cep.query.stream.impl.rete.integ.standalone.QueryTypeInfo@b3951d; ]> java.lang.NullPointerException at com.tibco.cep.query.gen.QEP0000000000000001$Expression00017.evaluate(QEP0000000000000001$Expression00017.java) at com.tibco.cep.query.stream.expression.EqualsExpressionEvaluator.evaluateBoolean(EqualsExpressionEvaluator.java:54) at com.tibco.cep.query.stream.impl.rete.join.CustomEqualsCondition.eval(CustomEqualsCondition.java:191)Body: >>>>>>>>>>>>>>>>>>>>>>>>>>>>
Example for the query which would give the above exception:
select m.NAME,b.NAME from MASTERBOOK m ,BOOK b where m.NAME = b.MASTERBOOK and m.NAME =$m1
Where 'm1' is the bind variable.
Resolution: ======== You need to put the condition with bind variable in brackets.
select m.NAME,b.NAME from MASTERBOOK m ,BOOK b where m.NAME = b.MASTERBOOK and (m.NAME =$m1)
Also, a defect (CR # 1-9ZCWVL) is also reported with TIBCO BusinessEvents 3.0.1 HF4
Issue/Introduction
Query Agent will throw null pointer exception while executing a query with bind variable.