My Oracle Support Banner

No Results Found When Using Querytasks Method Of Taskqueryservice With A Predicate On Identitytype (Doc ID 1441756.1)

Last updated on SEPTEMBER 04, 2018

Applies to:

Oracle Business Process Management Suite - Version 11.1.1.4.0 and later
Information in this document applies to any platform.
***Checked for relevance on 05-November-2013***

Symptoms


When searching for tasks assigned to a participant using the buildIdentityTypeGroupAssigneesPredicate method against theWFTASK_ASSIGNEES_COLUMN it doesn't return any results.

Here's an attached project which can be run in JDeveloper.

Example:


public List<IdentityType> buildIdentityTypeGroupAssigneesPredicate(List<String> groupNameList) {
List<IdentityType> result = null;

if (groupNameList != null && !groupNameList.isEmpty()) {
result = new ArrayList<IdentityType>();

ObjectFactory factory = new ObjectFactory();
IdentityType identityType = null;

for(String s : groupNameList){
identityType = factory.createIdentityType();
identityType.setId(s);
identityType.setType(IWorkflowConstants.IDENTITY_TYPE_GROUP);
result.add(identityType);
}

}

groupAssigneesPredicate = new Predicate(TableConstants.WFTASK_ASSIGNEES_COLUMN, Predicate.OP_IN, buildIdentityTypeGroupAssigneesPredicate(groupNameList));
Predicate searchPredicate = new Predicate(new Predicate(TableConstants.WFTASK_TASKDEFINITIONNAME_COLUMN, Predicate.OP_IS_NOT_NULL, (String)null),
Predicate.AND,
groupAssigneesPredicate);



However, using a string based predicate it will return results:


public List<String> buildStringGroupAssigneesPredicate(List<String> groupNameList) {
List<String> result = null;

if (groupNameList != null && !groupNameList.isEmpty()) {
result = new ArrayList<String>();

for(String s : groupNameList){
result.add(s + "," + IWorkflowConstants.IDENTITY_TYPE_GROUP);
}
}

return result;
}

groupAssigneesPredicate = new Predicate(TableConstants.WFTASK_ASSIGNEES_COLUMN, Predicate.OP_IN, buildStringGroupAssigneesPredicate(groupNameList));
Predicate searchPredicate = new Predicate(new Predicate(TableConstants.WFTASK_TASKDEFINITIONNAME_COLUMN, Predicate.OP_IS_NOT_NULL, (String)null),
Predicate.AND,
groupAssigneesPredicate);

Cause

To view full details, sign in with your My Oracle Support account.

Don't have a My Oracle Support account? Click to get started!


In this Document
Symptoms
Cause
Solution


This document is being delivered to you via Oracle Support's Rapid Visibility (RaV) process and therefore has not been subject to an independent technical review.
My Oracle Support provides customers with access to over a million knowledge articles and a vibrant support community of peers and Oracle experts.