No tool generated this mapping, it's hand made by me. I don't see what
should be wrong or verbose with this. Isn't it just the basic
definitions?

The Id "must" be generated by the database. Using -1 for the unsaved-
value is because 0 is a default value, so some kind of valid value, if
you want. But that could be easily changed, if it's only this that
causes the problem.

What I forgot to say in my first post is, that the exception only
occures when trying to save using Session.SaveOrUpdate. It works fine
using Session.Save, but in that case I'd have to handle the state
myself (finding out if the object/entity is new or changed).
I don't know if this is important, but on the database, there is also
a trigger that updates UpdatedUtc whenever the record is changed.
--~--~---------~--~----~------------~-------~--~----~
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