If a base class (mapped superclass) has a generic attribute and there are more than one subclasses (entities) with different (concrete) attribute types, hibernate 6 will incorrectly use the first (alphabetically) attribute type as required for all entities. This in turn causes an exception when trying to query using the generic attribute. Minimal test case: https://github.com/kuba-wu/h6-demo This used to work in Hibernate < 6. Issue confirmed with latest stable (6.1.7) and devel (6.2.0.CR2). |