[jboss-user] [EJB/JBoss] - Ignoring empty contained entities
bluetrade
do-not-reply at jboss.com
Sat Jul 15 17:45:51 EDT 2006
Hi,
I have a question regarding the possibility to ignore entities dynamically, based on whether or not they contain data. Let me explain:
class Person implements Serializable {
private Information info = new Information();
private String name;
...
}
now I don't want to save the information in case it remains empty, but at the same time I want to make use of the cascading functionality, but at times, Persons don't have information the information object would be empty. I cannot just leave it out, since I work with Seam and info.description for example might be injected, but if that field for example is null, I would like to ignore the info object so that I don't have any null-containing rows in the database. Also the not-null annotation does not help me...
Any ideas?
Thanks!!!
View the original post : http://www.jboss.com/index.html?module=bb&op=viewtopic&p=3958294#3958294
Reply to the post : http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=3958294
More information about the jboss-user
mailing list