I have a set of reference data. These classes are mapped as mutable=false.
I perform a simple query which is "from Product"; IE getting everything.
I then get an error in my application because Hibernate tries to insert some objects that have nulls for non-nullable fields. It does this because it tries to insert them before I am ready to have them inserted; the insert is triggered by an autoflush.
After reading, I found that autoflush is sometimes triggered if "there are changes held in memory that would affect the results of the query". However, there should not be any objects in memory that belong to this table that are modified. Is there any way I can get Hibernate to tell me what it thinks is different between what is in memory and what is in the database?
Hibernate version: 3.0.5
|