HHH-12565 Fix that returns the discriminator constant instead of column reference for leaf subtypes
This commit is contained in:
parent
f972dd4d29
commit
f62cecc62b
|
@ -338,8 +338,12 @@ public abstract class AbstractEntityPersister
|
|||
}
|
||||
|
||||
public String getDiscriminatorColumnReaderTemplate() {
|
||||
if ( getEntityMetamodel().getSubclassEntityNames().size() == 1 ) {
|
||||
return getDiscriminatorSQLValue();
|
||||
} else {
|
||||
return Template.TEMPLATE + "." + DISCRIMINATOR_ALIAS;
|
||||
}
|
||||
}
|
||||
|
||||
protected String getDiscriminatorAlias() {
|
||||
return DISCRIMINATOR_ALIAS;
|
||||
|
|
Loading…
Reference in New Issue