Hi everybody.
I’ve been working with NHibernate in a really big project and nowadays I’m having some problems with transactions, I’ve made some tests and I found a possible solution using two sessions, with the first one I access to the database out of the transaction, the second one is the session I use to persist object within the transaction, but, finally, I’ve found a new problem, when I’m working with objects witch Id unsaved value is cero my alternative solution works OK, but, when I’m working with object witch Id unsaved value is Any, NHibernate tries to insert a new row instead of updating someone.
Can somebody help me with my problem?
Or, Can somebody give me some explanation about how NHibernate knows when insert a new row or update someone?
Thanks, Martín
|