| This is a followup of this Stackoverflow question: http://stackoverflow.com/questions/37894280/hibernate-search-mysql-error-too-many-joins-with-joined-inheritance-model . When we query only one subtype of a hierarchy, CriteriaObjectInitializer creates a Criteria on the root type of the hierarchy while we could create a Criteria on the subtype only. This would avoid a lot of joins when having a complex hierarchy. |