From 74b811d99a79a281527ec2dfe273f79ad67e173e Mon Sep 17 00:00:00 2001 From: Marco Belladelli Date: Tue, 7 Feb 2023 21:41:01 +0100 Subject: [PATCH] HHH-16137 Fix check when replacing jdbc parameter --- .../org/hibernate/query/sqm/sql/BaseSqmToSqlAstConverter.java | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/hibernate-core/src/main/java/org/hibernate/query/sqm/sql/BaseSqmToSqlAstConverter.java b/hibernate-core/src/main/java/org/hibernate/query/sqm/sql/BaseSqmToSqlAstConverter.java index 1c052c3811..e8fcb40887 100644 --- a/hibernate-core/src/main/java/org/hibernate/query/sqm/sql/BaseSqmToSqlAstConverter.java +++ b/hibernate-core/src/main/java/org/hibernate/query/sqm/sql/BaseSqmToSqlAstConverter.java @@ -5210,7 +5210,7 @@ public abstract class BaseSqmToSqlAstConverter extends Base for ( List parameters : jdbcParamsForSqmParameter ) { assert parameters.size() == 1; final JdbcParameter jdbcParameter = parameters.get( 0 ); - if ( ( (SqlExpressible) jdbcParameter ).getJdbcMapping() != valueMapping ) { + if ( ( (SqlExpressible) jdbcParameter ).getJdbcMapping() != jdbcMapping ) { final JdbcParameter newJdbcParameter = new JdbcParameterImpl( jdbcMapping ); parameters.set( 0, newJdbcParameter ); jdbcParameters.getJdbcParameters().remove( jdbcParameter );