Hello Simone, actually, it looks like exposing FK field[s] as non-null CMP field[s]. Just map FK fields to CMP fields in jbosscmp-jdbc.xml.
NOTE: there is currently a bug (stack overflow on loading) in FK fields map to CMP columns. I can't commit changes to CVS the whole day. I hope Dain will help help me and today it'll be fixed in CVS. alex Monday, March 24, 2003, 3:45:54 PM, Simone Milani wrote: SM> Hi Alex, SM> Thanks! Do I have to expose the FK field in my ChildBean? Could you SM> provide an example? SM> Thanks!!!! SM> Simone SM> ----- Original Message ----- SM> From: "Alex Loubyansky" <[EMAIL PROTECTED]> SM> To: "Jonathan.O'[EMAIL PROTECTED]" <[EMAIL PROTECTED]> SM> Sent: Monday, March 24, 2003 12:06 PM SM> Subject: Re[2]: [JBoss-user] CMR with FK in the database >> JBoss-3.2 now supports NON-NULL foreig keys if foreign key fields are >> mapped to NON NULL CMP fields. >> >> alex >> >> Monday, March 24, 2003, 1:50:17 PM, Jonathan O'Connor wrote: >> >> JOCxd> Simone, >> JOCxd> Look for previous messages about INSERT after ejbPostCreate. >> JOCxd> If you use oracle you can also mark the NON NULL constraint as SM> DEFERRABLE >> JOCxd> INITIALLY DEFERRED. However, lots of DBAs don't like this. >> JOCxd> Ciao, >> JOCxd> Jonathan O'Connor >> >> >> >> >> >> JOCxd> "Simone Milani" <[EMAIL PROTECTED]> >> JOCxd> Sent by: [EMAIL PROTECTED] >> JOCxd> 24.03.2003 10:43 >> JOCxd> Please respond to jboss-user >> >> >> JOCxd> To: <[EMAIL PROTECTED]> >> JOCxd> cc: >> JOCxd> Subject: [JBoss-user] CMR with FK in the database >> >> >> JOCxd> Hi, >> >> JOCxd> I have a one to many relation with a FK constaint and the FK in SM> the >> JOCxd> children declared as non nullable. The SQL that is generated by SM> JBoss >> JOCxd> seems to violate this constraint. >> >> JOCxd> Please help!!! >> >> >> JOCxd> Thanks >> >> JOCxd> Simone ------------------------------------------------------- This sf.net email is sponsored by:ThinkGeek Welcome to geek heaven. http://thinkgeek.com/sf _______________________________________________ JBoss-user mailing list [EMAIL PROTECTED] https://lists.sourceforge.net/lists/listinfo/jboss-user