Hi All,

I have a object with below relationship

public class A {


       @Id
       @SequenceGenerator(name = "ID_GENERATOR", sequenceName = "Id_SEQ", 
allocationSize = 1)
       @GeneratedValue(strategy = GenerationType.SEQUENCE, generator = 
"ID_GENERATOR")
       @Column(name = "id")
       private BigDecimal id;


       @OneToMany(mappedBy = MST, orphanRemoval = true, cascade = { 
CascadeType.ALL})
       @OrderBy("id DESC")
       private List<B> b = new ArrayList<B>();

@Column(name = "name")
       private String name;

}

When I modify class A'S SAY name attribute and say dao.persist(A) then 
onFlushDirty()[overridden in my Hibernate interceptor] is also invoked even if 
B object is not modified

I am not understanding why hibernate is treating List<B> objects to be dirty 
when I am trying to save the parent object A

Regards,
Nitin
MASTEK LTD.
In the US, we're called MAJESCOMASTEK

~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
Opinions expressed in this e-mail are those of the individual and not that of 
Mastek Limited, unless specifically indicated to that effect. Mastek Limited 
does not accept any responsibility or liability for it. This e-mail and 
attachments (if any) transmitted with it are confidential and/or privileged and 
solely for the use of the intended person or entity to which it is addressed. 
Any review, re-transmission, dissemination or other use of or taking of any 
action in reliance upon this information by persons or entities other than the 
intended recipient is prohibited. This e-mail and its attachments have been 
scanned for the presence of computer viruses. It is the responsibility of the 
recipient to run the virus check on e-mails and attachments before opening 
them. If you have received this e-mail in error, kindly delete this e-mail from 
desktop and server.
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
_______________________________________________
hibernate-dev mailing list
hibernate-dev@lists.jboss.org
https://lists.jboss.org/mailman/listinfo/hibernate-dev

Reply via email to