[hibernate-issues] [Hibernate-JIRA] Created: (ANN-603) Using @CollectionOfEelements with FetchMode.JOIN and FetchType.EAGER to map a Map breaks Example criteria
Philippe Laflamme (JIRA)
noreply at atlassian.com
Tue Apr 24 11:56:04 EDT 2007
Using @CollectionOfEelements with FetchMode.JOIN and FetchType.EAGER to map a Map breaks Example criteria
---------------------------------------------------------------------------------------------------------
Key: ANN-603
URL: http://opensource.atlassian.com/projects/hibernate/browse/ANN-603
Project: Hibernate Annotations
Issue Type: Bug
Components: search
Affects Versions: 3.3.0.ga
Environment: hibernate-core-3.2.2.jar
Reporter: Philippe Laflamme
Attachments: ann-example_eager_join.patch
I'm using CollectionOfElements to map a Map<String, @Embeddable>. I want it to eagerly join the associated table to fill the map.
When I load the Entity using its PK, I obtain a single object with multiple entries in the Map, which is the expected behaviour. If I load the same Entity using an Example criteria (matching one of its property), I get one Entity per entry in the Map.
If you use FetchMode.SELECT, the resulting Example query returns a single entity with multiple values in the Map (expected behaviour).
Attached is a patch against annotations_3_3_0_GA that creates a test case in CollectionElementTest that reproduces the problem.
--
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