RE: Flushing new/dirty Objects before Query

From: Fehlhammer, Manuel (manuel.fehlhamme..dm.de)
Date: Thu Nov 20 2003 - 17:01:17 EST

  • Next message: Andrus Adamchik: "Re: Flushing new/dirty Objects before Query"

     Hi Andrus,

    >If you perform a query and it brings back some of the objects that you
    >have already modified but haven't committed, Cayenne will merge DB
    >changes with your object changes (never overwriting any of your
    >changes). If there is an unmodified cached object in the DataContext,
    >it is fully refreshed using new DB data. This is very reasonable
    >behavior, I guess it should suit your needs.
    >
    >Andrus

    does this hold also for new objects? Then I must carefully check my usecase... I created an object - registered it with the DataContext and then tried to find exactly this object via selectquery (before doing commitChanges()), but it wasn't found.

    I think this new object should be found because it exists already in the current context.

    Manuel



    This archive was generated by hypermail 2.0.0 : Thu Nov 20 2003 - 17:01:26 EST