openjpa-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Fay Wang (JIRA)" <j...@apache.org>
Subject [jira] Commented: (OPENJPA-1893) Missing join clause in query with collection-table with two join-columns
Date Mon, 22 Nov 2010 17:04:13 GMT

    [ https://issues.apache.org/jira/browse/OPENJPA-1893?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12934509#action_12934509
] 

Fay Wang commented on OPENJPA-1893:
-----------------------------------

Hi Patrice, 
   Could you post your Feature.java, your embedded id class, and embeddable class used in
the element collection? Thanks!

> Missing join clause in query with collection-table with two join-columns
> ------------------------------------------------------------------------
>
>                 Key: OPENJPA-1893
>                 URL: https://issues.apache.org/jira/browse/OPENJPA-1893
>             Project: OpenJPA
>          Issue Type: Bug
>    Affects Versions: 2.0.1
>            Reporter: Patrice DUROUX
>
> Considering the following mapping:
> 	<entity class="Feature">
> 		<table name="features" />
> 		<attributes>
> 			<embedded-id name="id" />
> 			<element-collection name="attributes">
> 				<collection-table name="qualifiers" />
> 			</element-collection>
> 		</attributes>
> 	</entity>
> Without specifying any JoinColumn element in the CollectionTable element, I got the query:
> (...) INNER JOIN qualifiers t3 ON t0.index = t3.FEATURE_INDEX AND t0.oid = t3.FEATURE_OID
(...)
> but changing the mapping by:
> 				<collection-table name="qualifiers">
> 					<join-column name="oid" />
> 					<join-column name="index" />
> 				</collection-table>
> I got:
> (...) INNER JOIN qualifiers t3 ON t0.index = t3.index (...)
> where is missing the first JoinColumn.

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


Mime
View raw message