Red Hat Bugzilla – Bug 1266553
TaskQueryBuilder tests failing - missing expression
Last modified: 2016-09-20 01:13:17 EDT
Description of problem:
Test TaskQueryBuilderCoverageTest.taskQueryBuilderCoverageTest, which is located in module jbpm-human-task fails when executed on supported production DB systems. Exception thrown on Oracle 11gR2 is here: .
When tested with hibernate.show_sql=true property, it fails on this SQL statement: .
The problem is related to empty "IN" clauses. E.g. OR organizati2_.id IN ().
The solution can be that the IN clauses are not generated when they are empty.
Version-Release number of selected component (if applicable):6.2.0.ER3
Execute TaskQueryBuilderCoverageTest.taskQueryBuilderCoverageTest on one of supported production database systems.
The problem here is that some users will not have groups, but the query is adding a predicate/where phrase that references an empty criteria (no groups).
The solution is to make sure to only add those clauses (potOwner/stakeHolder/busAdmin in groups) when the user has 1+ groups.
These commits were also part of the fix:
Verified in 6.2.0.ER5 by running community test suite on supported DB systems. All failing tests pass now.