[hibernate-issues] [Hibernate-JIRA] Commented: (HHH-2889) owner of the fetched association was not present in the select list
Timo Nentwig (JIRA)
noreply at atlassian.com
Mon Oct 15 10:04:38 EDT 2007
[ http://opensource.atlassian.com/projects/hibernate/browse/HHH-2889?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel#action_28430 ]
Timo Nentwig commented on HHH-2889:
-----------------------------------
Here you go:
http://www.hibernate.org/250.html#A34
<quote>
"select b from A join fetch a.bees b" - this query makes no sense, remove the "fetch".
</quote>
Replace the query to "select new foo.Bar(a) from A join fetch a.bees b" and it makes sense but Hibernate throws the Exception anyway.
> owner of the fetched association was not present in the select list
> -------------------------------------------------------------------
>
> Key: HHH-2889
> URL: http://opensource.atlassian.com/projects/hibernate/browse/HHH-2889
> Project: Hibernate3
> Issue Type: Bug
> Components: core
> Affects Versions: 3.2.5
> Reporter: Timo Nentwig
> Assignee: Diego Pires Plentz
>
> This is known (and correct) to throw an exception:
> SELECT b FROM A a JOIN FETCH a.b b
> But this exception is also throws in this case:
> SELECT new Container(a) FROM A a JOIN FETCH a.b b
> IMHO this is a bug. The constructor of Container might want to have b fetched eagerly.
--
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: http://opensource.atlassian.com/projects/hibernate/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira
More information about the hibernate-issues
mailing list