Hi,
I need to model a large number of n:m relations in my project, e.g. I have a
class named 'Component', which contains a Vector of 'Feature' objects:
public class Component {
private Vector features;
}
I want to model the Component class as a BMP entity bean. I can think of
three possible strategies:
1. Use a 'link' table, consisting of (componentId, featureId). However, my
project contains a large number of different n:m relations, which would
result in creating one link table for every Vector I use :-(
2. I could store the primary keys of the Feature entities in the Vector, and
store a serialized version of that Vector in the database with every
Component record. Thus, I would not need an additional table
3. Like (2), but instead of primary keys I could store entity bean handles in
the Vector (hmmm I wonder if this is a good idea?)
Variant (1) would be the traditional database approach, however I would
prefer (2) or (3), since they are easier to handle.
What do you think?
thx
Heiko
===========================================================================
To unsubscribe, send email to [EMAIL PROTECTED] and include in the body
of the message "signoff EJB-INTEREST". For general help, send email to
[EMAIL PROTECTED] and include in the body of the message "help".