Need help with Hibernate? Read this first:
http://www.hibernate.org/ForumMailingli ... AskForHelp
Hibernate version: 2.1.6
Mapping documents:
<class
name="erp.dataaccesslayer.hibernate.dataobjects.Fitting"
table="Fittings"
>
<id
name="id"
type="java.lang.String"
column="id"
>
<generator class="assigned" />
</id>
<property
name="name"
type="java.lang.String"
column="name"
not-null="true"
length="50"
/>
</class>
<joined-subclass
name="erp.dataaccesslayer.hibernate.dataobjects.OtherFitting"
table="OtherFittings" extends="erp.dataaccesslayer.hibernate.dataobjects.Fitting"
>
<key column="id"/>
<property
name="desc"
type="java.lang.String"
column="desc"
not-null="true"
length="50"
/>
</joined-subclass>
I have read the post "Inheritance and Left Outer Joins Generating Large Queries".
In that post, Gavin wrote:
And for a query against a concrete subclass, the two strategies both result in a single query with a join across 3 or 4 tables.
How come I stilll get a large query when the query is against one of the concrete subclasses?
Thank you!