Greetings, I have a very large app using a active state model, and Im
in a bit of a pickle.

I have a batch import utility that imports new and updated objects.
Here is the problem:

record comes in, decides to update a record. loads the object and
makes modifications. Including changing a collection. It then calls a
validate function that checks the data (including one that does a
session.find and thus a flush). At that point the object is written to
the DB. But then the validation fails (because of something it found
in that find.)

Now we have a interceptor registered which overrides finddirty and
preflush and evicts anything that has not been explicitly saved. But
because of that collection change the object gets persisted even
though the interceptor has evicted the parent object.

Is there any way to get around this? to add to a collection without
nHibernate persisting that until I say so? This is resulting in bad
data being persisted to the db. Also because of the way our active
state model works we cannot easily roll back just the transaction for
that particular object (there is a whole lot of other things going on)
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups 
"nhusers" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to 
[email protected]
For more options, visit this group at 
http://groups.google.com/group/nhusers?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to