hibernate-orm
hibernate-orm copied to clipboard
HHH-18629 Fix inconsistent column alias generated while result class is used for placeholder
wrong fileid’s alias fileid1_0_0_ is used instead of fileid1_0_1_ while transforming ResultSet to Book.
Column "fileid1_0_0_" not found [42122-224]
org.h2.jdbc.JdbcSQLSyntaxErrorException: Column "fileid1_0_0_" not found [42122-224]
at org.h2.message.DbException.getJdbcSQLException(DbException.java:514)
at org.h2.message.DbException.getJdbcSQLException(DbException.java:489)
at org.h2.message.DbException.get(DbException.java:223)
at org.h2.message.DbException.get(DbException.java:199)
at org.h2.jdbc.JdbcResultSet.getColumnIndex(JdbcResultSet.java:3492)
at org.h2.jdbc.JdbcResultSet.findColumn(JdbcResultSet.java:178)
at org.hibernate.sql.results.jdbc.internal.AbstractResultSetAccess.resolveColumnPosition(AbstractResultSetAccess.java:63)
[Please describe here what your change is about]
By submitting this pull request, I confirm that my contribution is made under the terms of the Apache 2.0 license and can be relicensed under the terms of the LGPL v2.1 license in the future at the maintainers' discretion. For more information on licensing, please check here.
https://hibernate.atlassian.net/browse/HHH-18629