I don't remember if @PrimaryKeyJoinColumn exists in RC3, but you can try this
out on the RC4 release that we are putting out today.
| @Entity
| public class One {
| private OnePK one;
| private Two two;
|
| @EmbeddedId
| public OnePk getPK() { return a; }
| public setPK(OnePK) { this.one= one; }
|
| @ManyToOne
| @PrimaryKeyJoinColumn(name="a_column_name")
| public Two getTwo() { return two; }
| public setTwo(Two two) { this.two = two; }
| }
|
| @Embeddable
| OnePK (
| private int a;
| private int b;
|
| // get/set methods
| @Column("a_column_name")
| public getA() { return a; }
| }
|
|
either use @PrimaryKeyJoinColumn(name) or (referencedName) I don't remember
which is the right one off the top of my head.
View the original post :
http://www.jboss.com/index.html?module=bb&op=viewtopic&p=3920492#3920492
Reply to the post :
http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=3920492
-------------------------------------------------------
This SF.net email is sponsored by: Splunk Inc. Do you grep through log files
for problems? Stop! Download the new AJAX search engine that makes
searching your log files as easy as surfing the web. DOWNLOAD SPLUNK!
http://sel.as-us.falkag.net/sel?cmd=lnk&kid=103432&bid=230486&dat=121642
_______________________________________________
JBoss-user mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/jboss-user