On Sep 7, 3:11 pm, Michael Bayer <mike...@zzzcomputing.com> wrote: > > you want to make sure things are cached (which means they've been > pickled and therefore not related to the Session anymore) before the > Session is expired, which happens when you call rollback() or commit() > (or expunged, sure, though that's usually too much trouble - just the > pickling part of the story takes care of that usually). > alternatively you can disable expire_on_commit if that's what's > getting in the way.
Thanks, that did the trick. For the one cache I added the one line of code to expunge the objects first. For the other I copied the important data out into a namedtuple and saved myself some memory too. Cheers, -Dan --~--~---------~--~----~------------~-------~--~----~ You received this message because you are subscribed to the Google Groups "sqlalchemy" group. To post to this group, send email to sqlalchemy@googlegroups.com To unsubscribe from this group, send email to sqlalchemy+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/sqlalchemy?hl=en -~----------~----~----~----~------~----~------~--~---