This cannot work. Don't get your ISession by hand, but use a SessionScope
instead. ARIntegration supports ATM only via scopes.

-Markus

2009/8/15 zorwi <[email protected]>

> the new funtion  which I want to be control by
> AutomaticTransactionManagement
>         {
>            ISessionFactoryHolder sessionHolder =
> ActiveRecordMediator.GetSessionFactoryHolder();
>            ISession session = sessionHolder.CreateSession(typeof
> (Customer));
>
>            System.Data.IDbCommand command =
> session.Connection.CreateCommand();
>             session.Transaction.Enlist(command);
>             command.CommandText = "update Customer set " + columns +
> "=" + value;
>            command.ExecuteNonQuery();
>            sessionHolder.ReleaseSession(session);
>        }
>

--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups 
"Castle Project Users" 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/castle-project-users?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to