This week's book giveaway is in the Servlets forum.
We're giving away four copies of Murach's Java Servlets and JSP and have Joel Murach on-line!
See this thread for details.
The moose likes EJB and other Java EE Technologies and the fly likes why create related CMPs? Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login

Win a copy of Murach's Java Servlets and JSP this week in the Servlets forum!
JavaRanch » Java Forums » Java » EJB and other Java EE Technologies
Bookmark "why create related CMPs?" Watch "why create related CMPs?" New topic

why create related CMPs?

Maulin Vasavada
Ranch Hand

Joined: Nov 04, 2001
Posts: 1871
Hi all,
I know that when we create related CMPs it puts those methods returning Collection in one side in 1-to-N relation and etc things but I am trying to come up with more convincing reasons for need of related CMPs. Here are my thoughts so far,
1. when we create related CMPs it inserts relationship management methods automatically which could help programmers to "not worry about" foreign key constraints etc...
more input?
Sergiu Truta
Ranch Hand

Joined: Dec 16, 2003
Posts: 121
Having CMR and the container to handle relationships is a great ease for a developer. I think this is enough as a reason for using relationships in CMP . I'm walking the path...
It is sorta covered in the JavaRanch Style Guide.
subject: why create related CMPs?
Similar Threads
Adapter pattern and DB interface
CMP Method Names
How to change package of CMPs in WSAD
Where should business method be placed anyway