[jboss-user] [EJB/JBoss] - Re: 4.0.4.GA - @javax.persistence.OneToMany(mappedBy) - brok

smix007 do-not-reply at jboss.com
Tue Dec 5 06:17:30 EST 2006


hello, 
I have practically the same problem that you:

in TermProj

  | public class TermProj implements Serializable {    
  |     
  |     @EmbeddedId
  |     protected TermProjPK termProjPK;
  | //join with TermSource
  |     @ManyToOne
  |     @JoinColumn (name = "AUIW")
  |     private TermSource  auiw;  
  |     public TermSource getAuiw() {
  |         return auiw;
  |     }
  | 
  |     public void setAuiw(TermSource auiw) {
  |         this.auiw = auiw;
  |     }    
  |     
  |     
  |     //join with SnomedInter   
  |     @ManyToOne 
  |     @JoinColumn (name = "AUIS")
  |     private SnomedInter auis;
  |     public SnomedInter getAuis() {
  |         return auis;
  |     }
  | 
  |     public void setAuis(SnomedInter auis) {
  |         this.auis = auis;
  |     }
  | 
 public class TermSource implements Serializable {
  | 
  |     
  |     
  |     
  |     @Id
  |     @Column(name = "AUIW", nullable = false)
  |     private String auiw;
  |  [...]
  | @OneToMany(mappedBy="AUIW")
  |     private Collection<TermProj> termProjs;
  |     
  |      public Collection<TermProj> getTermProjs() {
  |         return termProjs;
  |     }
  | 
  |     public void setTermProjs(Collection<TermProj> termProjs) {
  |         this.termProjs = termProjs;
  |     }

  | public class SnomedInter implements Serializable {
  | 
  |     @Id
  |     @Column(name = "AUIS", nullable = false)
  |     private String auis;
  | [...]
  | @OneToMany(mappedBy="AUIS")
  |     private Collection<TermProj> termProjs;
  |     
  |     public Collection<TermProj> getTermProjs() {
  |         return termProjs;
  |     }
  | 
  |     public void setTermProjs(Collection<TermProj> termProjs) {
  |         this.termProjs = termProjs;
  |     }
  | 
  | 


how you solved this problem please

View the original post : http://www.jboss.com/index.html?module=bb&op=viewtopic&p=3991238#3991238

Reply to the post : http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=3991238



More information about the jboss-user mailing list