mirror of
https://github.com/ebean-orm/ebean.git
synced 2024-04-21 10:51:47 +00:00
This change also relates back to #1740 and #1744 and changes the way that issue was fixed (by SqlTreeNodeBean on partially populated non-id inheritance bean).
This commit is contained in:
@@ -227,7 +227,7 @@ class SqlTreeNodeBean implements SqlTreeNode {
|
||||
|
||||
@Override
|
||||
void initBeanType() throws SQLException {
|
||||
InheritInfo localInfo = inheritInfo.readType(ctx);
|
||||
InheritInfo localInfo = readId ? inheritInfo.readType(ctx) : desc.getInheritInfo();
|
||||
if (localInfo == null) {
|
||||
// the bean must be null
|
||||
localIdBinder = idBinder;
|
||||
@@ -539,7 +539,7 @@ class SqlTreeNodeBean implements SqlTreeNode {
|
||||
}
|
||||
|
||||
if (readId) {
|
||||
if (!subQuery && inheritInfo != null && inheritInfo.hasChildren()) {
|
||||
if (!subQuery && inheritInfo != null) {
|
||||
ctx.appendColumn(inheritInfo.getDiscriminatorColumn());
|
||||
}
|
||||
appendSelectId(ctx, idBinder.getBeanProperty());
|
||||
|
||||
Reference in New Issue
Block a user