Skip to content

Commit e9946db

Browse files
dreab8beikov
authored andcommitted
HHH-16974 IllegalStateException Unsupported tuple comparison combination
1 parent e7f9875 commit e9946db

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

hibernate-core/src/main/java/org/hibernate/sql/ast/spi/AbstractSqlAstTranslator.java

+2-1
Original file line numberDiff line numberDiff line change
@@ -7734,7 +7734,8 @@ else if ( needsTupleComparisonEmulation( operator ) ) {
77347734
else if ( ( rhsTuple = SqlTupleContainer.getSqlTuple( comparisonPredicate.getRightHandExpression() ) ) != null ) {
77357735
final Expression lhsExpression = comparisonPredicate.getLeftHandExpression();
77367736

7737-
if ( lhsExpression instanceof SelectStatement && ( (SelectStatement) lhsExpression ).getQueryPart() instanceof QueryGroup ) {
7737+
if ( lhsExpression instanceof SqlTupleContainer
7738+
|| lhsExpression instanceof SelectStatement && ( (SelectStatement) lhsExpression ).getQueryPart() instanceof QueryGroup ) {
77387739
if ( rhsTuple.getExpressions().size() == 1 ) {
77397740
// Special case for tuples with arity 1 as any DBMS supports scalar IN predicates
77407741
renderComparison(

0 commit comments

Comments
 (0)