AnsweredAssumed Answered

Custom Sql query and Serialize variable

Question asked by nik10.mah on Jun 3, 2014
Latest reply on Jun 4, 2014 by jbarrez
Hi,

I am passing a serialized bean named WfeBean( which contains entityId and statusId as fields) as process variable. And it seems it stores the bean in act_ge_bytearray table. Now i want  to create a query which fetches all the entityId of the tasks assigned to a user.
I am created a query as described in this blog http://www.jorambarrez.be/blog/2014/01/17/execute-custom-sql-in-activiti/.
Tis is the query i have made.
SELECT variable.NAME_ as variableValue FROM ACT_RU_VARIABLE variable",
   "inner join ACT_RU_TASK task on variable.PROC_INST_ID_ = task.PROC_INST_ID_",
   "where task.ASSIGNEE_ = #{assignee}" })



Now when i try to get the  wfeBean from result Map it gives me wfeBEan as string ans when i try to cast it it throws nullpointer exception.

So how can i get this object. Can i use native query for this.?


Outcomes