Closed AleksMeshkov closed 9 years ago
By the way, can I somehow rollback entity's changed (dirty) attributes to the last saved (flushed) state?
upd: I think I'v found it. It's persistence.clean(), right?
Every query you execute (e.g. list) will automatically flush, so that the query results will reflect changes made "locally" (i.e. not in the database). Indeed, clean() should reset "local" changes.
Thank you, @zefhemel!
Hello!
If I create a new obejct
then run
that object will be saved into the database even without running persistence.flush(). Should it be so? Can I somehow prevent this?