File tree Expand file tree Collapse file tree 2 files changed +3
-13
lines changed
hibernate-core/src/main/java/org/hibernate Expand file tree Collapse file tree 2 files changed +3
-13
lines changed Original file line number Diff line number Diff line change @@ -606,21 +606,11 @@ protected boolean supportsRowValueConstructorSyntax() {
606
606
return false ;
607
607
}
608
608
609
- @ Override
610
- protected boolean supportsRowValueConstructorSyntaxInInList () {
611
- return true ;
612
- }
613
-
614
609
@ Override
615
610
protected boolean supportsRowValueConstructorSyntaxInQuantifiedPredicates () {
616
611
return false ;
617
612
}
618
613
619
- @ Override
620
- protected boolean supportsRowValueConstructorSyntaxInInSubQuery () {
621
- return true ;
622
- }
623
-
624
614
@ Override
625
615
protected String getDual () {
626
616
return "dual" ;
Original file line number Diff line number Diff line change @@ -8285,14 +8285,14 @@ else if ( subquery != null && !supportsRowValueConstructorSyntaxInQuantifiedPred
8285
8285
else if ( needsTupleComparisonEmulation ( operator ) ) {
8286
8286
rhsTuple = SqlTupleContainer .getSqlTuple ( rhsExpression );
8287
8287
assert rhsTuple != null ;
8288
- // Some DBs like Oracle support tuples only for the IN subquery predicate
8289
- if ( ( operator == ComparisonOperator .EQUAL || operator == ComparisonOperator .NOT_EQUAL ) && supportsRowValueConstructorSyntaxInInSubQuery () ) {
8288
+ // If the DB supports tuples in the IN list predicate, use that syntax as it's more concise
8289
+ if ( ( operator == ComparisonOperator .EQUAL || operator == ComparisonOperator .NOT_EQUAL ) && supportsRowValueConstructorSyntaxInInList () ) {
8290
8290
comparisonPredicate .getLeftHandExpression ().accept ( this );
8291
8291
if ( operator == ComparisonOperator .NOT_EQUAL ) {
8292
8292
appendSql ( " not" );
8293
8293
}
8294
8294
appendSql ( " in (" );
8295
- renderExpressionsAsSubquery ( rhsTuple .getExpressions () );
8295
+ rhsTuple .accept ( this );
8296
8296
appendSql ( CLOSE_PARENTHESIS );
8297
8297
}
8298
8298
else {
You can’t perform that action at this time.
0 commit comments