Re: Synchronization after SQLTemplate

From: Cris Daniluk (cris.danilu..mail.com)
Date: Mon Sep 05 2005 - 16:37:44 EDT

  • Next message: Gili: "Re: Synchronization after SQLTemplate"

    I would store a separate collection of the objects you deleted, then
    invalidate them from the cache. Even still though, I'm not sure that
    this would catch all relationships and whatnot (it will probably just
    reset relationships back to hollow).

    Couldn't you just use DeleteQuery?

    Cris

    On 9/4/05, Gili <cowwo..bs.darktech.org> wrote:
    > Hi,
    >
    > http://www.objectstyle.org/cayenne/userguide/fetch/sqltemplate.html
    > mentions that ObjectStore might be inconsistent after a SQLTemplate, but
    > what are we supposed to do then? In Hibernate one would invoke
    > session.flush() which forces the synchronization of all cached objects
    > with the DB. Does Cayenne have an equivilent method?
    >
    > I want to be able to bulk-delete objects using SQLTemplate (as opposed
    > to using a SelectQuery) for performance reasons and then update the
    > cache so I can continue within the same data context.
    >
    > Gili
    > --
    > http://www.desktopbeautifier.com/
    >



    This archive was generated by hypermail 2.0.0 : Mon Sep 05 2005 - 16:37:45 EDT