From 115c6cdf27db10d9325f1ae5d2488951ba154a4d Mon Sep 17 00:00:00 2001 From: Andrea Boriero Date: Tue, 28 Jun 2022 12:39:27 +0200 Subject: [PATCH] HHH-15369 UnknownTableReferenceException when two subclasses have same field with different type --- .../src/main/java/org/hibernate/spi/NavigablePath.java | 1 + 1 file changed, 1 insertion(+) diff --git a/hibernate-core/src/main/java/org/hibernate/spi/NavigablePath.java b/hibernate-core/src/main/java/org/hibernate/spi/NavigablePath.java index c4d32f2733..ca2a9bd6fe 100644 --- a/hibernate-core/src/main/java/org/hibernate/spi/NavigablePath.java +++ b/hibernate-core/src/main/java/org/hibernate/spi/NavigablePath.java @@ -140,6 +140,7 @@ public class NavigablePath implements DotIdentifierSequence, Serializable { if ( ! Objects.equals( getAlias(), otherNavigablePath.getAlias() ) ) { return false; } + return Objects.equals( getRealParent(), otherNavigablePath.getRealParent() ); } return Objects.equals( getParent(), otherPath.getParent() );