The
problem has to do with the EJB spec. The spec says that the pk must be set
in the ejbCreate method and then can't be changed. The spec also says that
cmr fields can not be set until ejbPostCreate. Furthermore the spec only
allows cmp-fields in compound pks. I haven't thought of a way around this
yet. I'm considering supporting the mapping a cmp-field to the same
column as a cmr-field, but this opens a big can of worms. Most of the
interesting database fk mappings are not supported in JBossCMP yet (like not
null foreign keys). When I rewrite the cmr code the first time (I always
expect to write code 3 times) I plan on supporting the interesting fk
mappings.
-dain
|
- [JBoss-dev] fk in compound pk Ken Chang
- Re: [JBoss-dev] fk in compound pk Dain Sundstrom
- Re: [JBoss-dev] fk in compound pk Andreas Schaefer
- RE: [JBoss-dev] fk in compound pk Dan OConnor