HHH-15014 Fix subquery tuple rendering for H2 2.0.202+

This commit is contained in:
Christian Beikov 2022-01-06 18:30:55 +01:00
parent ad43a625ae
commit fe44411e60
1 changed files with 3 additions and 1 deletions

View File

@ -90,7 +90,9 @@ public class H2SqlAstTranslator<T extends JdbcOperation> extends AbstractSqlAstT
@Override @Override
public void visitInSubQueryPredicate(InSubQueryPredicate inSubQueryPredicate) { public void visitInSubQueryPredicate(InSubQueryPredicate inSubQueryPredicate) {
final SqlTuple lhsTuple; final SqlTuple lhsTuple;
if ( ( lhsTuple = SqlTupleContainer.getSqlTuple( inSubQueryPredicate.getTestExpression() ) ) != null // As of 1.4.200 this is supported
if ( getDialect().getVersion().isBefore( 1, 4, 200 )
&& ( lhsTuple = SqlTupleContainer.getSqlTuple( inSubQueryPredicate.getTestExpression() ) ) != null
&& lhsTuple.getExpressions().size() != 1 ) { && lhsTuple.getExpressions().size() != 1 ) {
inSubQueryPredicate.getTestExpression().accept( this ); inSubQueryPredicate.getTestExpression().accept( this );
if ( inSubQueryPredicate.isNegated() ) { if ( inSubQueryPredicate.isNegated() ) {