cancel
Showing results for 
Search instead for 
Did you mean: 

Count with OR(), processVariableValueEquals and taskAssignee

hybaken
Champ in-the-making
Champ in-the-making
Hello,
when I m using this filters on HistoricTaskInstanceQuery:
.or()
.processVariableValueEquals("VarTest", "test")
.taskAssignee("test")
.endOr();

and ask HistoricTaskInstanceQuery for count(), it returns incorrect number.
Seems some join in HistoricTaskInstance.xml is not correct. I tried to used the same select generated via api directly to database and it returns the rows with the same ACT_HI_TASKINST._ID.
3 REPLIES 3

jbarrez
Star Contributor
Star Contributor
Hmmm sounds like a bug. A unit test that demonstrates this problem helps us to get it fixed quickly!

soptik00
Champ in-the-making
Champ in-the-making
Hi, I have the same issue. I used simple two conditions in OR. Returned list of HistoricTaskInstance is correct (for me is size 4). Only count is in this case wrong ( for me 140). 
Will be this issue fixed in next version?

Thank for help.
            
<java>
query.or();
query.processVariableValueEquals(WorkflowProcessInstanceService.APPLICANT_USERNAME, loggedUsername);
query.processVariableValueEquals(WorkflowProcessInstanceService.IMPLEMENTER_USERNAME, loggedUsername);
//query.taskInvolvedUser(loggedUsername);
query.endOr();
</java>

hybaken
Champ in-the-making
Champ in-the-making
I didn't have time to create unit test for it.

I don't know if it was fixed in higher version.

But I was able to find it quite easy in some xml file of ibatis/mybatis that are used in activiti as I remember. Unfortunately I do not have access to this code anymore. So I cant help you much. But in case it' s not fixed yet, you can find it there.
Getting started

Tags


Find what you came for

We want to make your experience in Hyland Connect as valuable as possible, so we put together some helpful links.