Re: [sqlalchemy] How to revert all changes on an object before Session.merge(o, load=False) ?

2011-11-29 Thread Michael Bayer
On Nov 29, 2011, at 2:35 PM, Łukasz Czuja wrote: > Hello, > > I'm trying to figure out a way to use Session.merge(o, load=False), on > an object which is not bound to a session (Session.remove() used after > the object was modified, but the changes were not commited). > > When the object's stat

[sqlalchemy] How to revert all changes on an object before Session.merge(o, load=False) ?

2011-11-29 Thread Łukasz Czuja
Hello, I'm trying to figure out a way to use Session.merge(o, load=False), on an object which is not bound to a session (Session.remove() used after the object was modified, but the changes were not commited). When the object's state is modified (instance_state(o).modified == True) the session me