Win a copy of The Java Performance Companion this week in the Performance forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

Multiple Tables catered by a single BMP

 
Gaurav Jain
Ranch Hand
Posts: 108
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Can multiple tables be catered by a single BMP or if there are x tables then x BMP's need to be created??
 
Nathaniel Stoddard
Ranch Hand
Posts: 1258
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
BMP entity beans' persistence is all done by the bean developer. That means that you can use whatever method you want to load/store the bean's state -- even multiple tables, datasources, anything.
However, note that where entity beans are persisted when using a database is a deployment/server issue. I'm sure some allow you to persist a CMP entity bean to multiple tables if necessary (subsets going to each, that is). In fact, I seem to recall JBoss giving this ability, although my memory sometimes plays cruel jokes on me. You'll have to investigate by looking at the jboss-cmp DTD. (This of course would alleviate you from having to deal with all the BMP issues -- a very good thing!)
By the way, that was my Martha joke for the day. Exciting huh?
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic