As written by Oskar, Update is useless in your case. For this function is not meant to perform a sql update on database. Its purpose is to attach a detached object to a session. Changes to object are tracked by the session for all objects it has loaded, and automatically persisted in DB on flush.
I do not know what causes your problem. But I am wondering why you choose this way of handling a session. Using begin request and end request looks a bit like a webform solution. In a MVC application, action filters should be preferred instead. Beware that this suppose you do not pass to your views NHibernate mapped objects with uninitialized lazy properties waiting to be accessed. For during view rendering, a NHibernate session management action filter would already have close the session, causing lazy-initialization to fail. -- You received this message because you are subscribed to the Google Groups "nhusers" group. To unsubscribe from this group and stop receiving emails from it, send an email to [email protected]. To post to this group, send email to [email protected]. Visit this group at http://groups.google.com/group/nhusers?hl=en. For more options, visit https://groups.google.com/groups/opt_out.
