File APIs for Java Developers
Manipulate DOC, XLS, PPT, PDF and many others from your application.
http://aspose.com/file-tools
The moose likes EJB Certification (SCBCD/OCPJBCD) and the fly likes @IdClass and @EmbeddedId Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login
JavaRanch » Java Forums » Certification » EJB Certification (SCBCD/OCPJBCD)
Bookmark "@IdClass and @EmbeddedId" Watch "@IdClass and @EmbeddedId" New topic
Author

@IdClass and @EmbeddedId

nitin pai
Ranch Hand

Joined: May 30, 2006
Posts: 185
@EmbeddedId is a good way to work with composite primary keys. But why does @IdClass exist. It anyways introduces redundancies and can be error prone.

Can you cite any specific scenario where only @IdClass can be used and not @EmbeddedId?



 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: @IdClass and @EmbeddedId
 
Similar Threads
Problem in persisting Entity with Composite Key
Invalid composite primary key specification
Annotions doubt
Composite key classes
@IdClass and @EmbeddedId