HHH-10729 HHH-9021 HHH-10230 - Fix Issue with literals in select expression

(cherry picked from commit e71af130f0)
This commit is contained in:
Andrea Boriero 2016-06-19 12:00:49 +01:00 committed by Gail Badner
parent 9bf4a829c5
commit 6ecd2bd472
2 changed files with 2 additions and 5 deletions

View File

@ -428,7 +428,7 @@ selectExpr
| functionCall
| count
| collectionFunction // elements() or indices()
| literal
| constant
| arithmeticExpr
| logicalExpr
| parameter

View File

@ -110,10 +110,7 @@ public class CriteriaQueryImpl<T> extends AbstractNode implements CriteriaQuery<
selection = ( Selection<? extends T> ) criteriaBuilder().tuple( selections );
}
else if ( getResultType().isArray() ) {
selection = ( Selection<? extends T> ) criteriaBuilder().array(
( Class<? extends Object[]> ) getResultType(),
selections
);
selection = criteriaBuilder().array( getResultType(), selections );
}
else if ( Object.class.equals( getResultType() ) ) {
switch ( selections.size() ) {