This week's book giveaway is in the OO, Patterns, UML and Refactoring forum. We're giving away four copies of Refactoring for Software Design Smells: Managing Technical Debt and have Girish Suryanarayana, Ganesh Samarthyam & Tushar Sharma on-line! See this thread for details.
Hey all. I need your help please. I have two CMP beans, PlayerBean and TeamBean. the relationship is one to many and bidirectional. TeamBean has a CMR field called plalyers and PlayerBean has a CMR field called team, and there are a setter and getter methods for these fields in each bean. the database schema for TeamBean is : TEAM_NAME, TEAM_CITY and the bean contains the following fields : name, city the database schema for Player bean is : ID, FULLNAME, NAME // name is the name of the city and the bean contained the following fields : id, fullname, name here is a snipet from jboss-jdbc.xml :
my questions are : 1. is the relationships element right ? 2. what is the value of <field-name> should be ? id (which is the name of a field in PlayerBean class) or ID (which is the name of the field in database schema) ? 3. what is the value of <column-name> should be ? TEAM_NAME (which is the name of a field in Team database schema) or NAME (which is the name of a field in Player database schema) or name (which is the name of a field in PlayerBean class) ?? 4. which sould has the <foreign-key-mapping> element , TeamBean or PlayerBean ?
</ejb-relationship-role> <ejb-relationship-role> <ejb-relationship-role-name>Team-Has-Players</ejb-relationship-role-name> <key-fields> <key-field> <field-name>id</field-name> <!--field name of primary key of Team table--> <column-name>teamId</column-name> <!--field name of team id in Player table </key-field> </key-fields> </ejb-relationship-role> </ejb-relation>
I’ve looked at a lot of different solutions, and in my humble opinion Aspose is the way to go. Here’s the link: http://aspose.com