| Author |
why referencedColumnName element missing in Joined table startegy
|
Karnati Sudhakar
Ranch Hand
Joined: Aug 26, 2008
Posts: 270
|
|
Hi All, In EJB in Action book on page number 288 the Joined Table strategy is explained and it is implemented by the OnetoOne relationships between the Child and parent class. Here the code given on this page I just want to know why the referencedColumnName element is missing in the @PrimarykeyJoinColumn annnotation. Regards Sudhakar
|
Regards
Sudhakar
|
 |
Amandeep Singh
Ranch Hand
Joined: Jul 17, 2008
Posts: 833
|
|
|
Don't worry, even if referenceColumnName attribute is missing. It will join with the primary key's of other table's. It's a default behaviour.
|
SCJP 1.4, SCWCD 5, SCBCD 5, OCPJWSD 5,SCEA-1, Started Assignment Part 2
My blog- http://rkydesigns.blogspot.com
|
 |
Mellon Sun
Ranch Hand
Joined: Feb 20, 2003
Posts: 126
|
|
http://www.coderanch.com/t/418895/java-EJB-SCBCD/certification/type-JoinColumn It seems like referencedColumnName element can be missing in @OneToOne @JoinColumn too. What confusing me is when I point out the referencedColumnName I encounter an error because the referenced column is generated with a wrong type.
|
SCJP,SCWCD1.3,SCWCD1.4,SCJD,SCBCD5,SCEA5
|
 |
 |
|
|
subject: why referencedColumnName element missing in Joined table startegy
|
|
|