Re: Relationships refresh possible BUG

From: Andrus Adamchik (andru..bjectstyle.org)
Date: Wed Jun 17 2009 - 10:38:38 EDT

  • Next message: Mark Fraser: "Object Validation Auto Increment Problem"

    On Jun 17, 2009, at 5:31 PM, lmarcha..mausa.com wrote:

    > Thanks for the clarification, I (mis)understood what was
    > RefreshQuery().
    > If I understand well "invalidating" means that it will not refresh
    > the cached relationships but will only detect the added/removed
    > relationships ?

    yes. we are invalidating a single object, not the entire object graph.

    > So the only way (without prefetching) to _fully_ update the
    > relationships of an object is to :
    > 1) RefreshQuery() -> update the root object and invalidate it's
    > relationships so it will detect the relationship adding/removal the
    > on next access. (but will not refresh the relationships values)
    > 2) Use RelationshipQuery() to refresh the values of the already
    > cached relationships.
    >
    > Is my understanding OK ?

    I never thought of it, but I guess that should work. I suggest to use
    prefetching though.

    Andrus



    This archive was generated by hypermail 2.0.0 : Wed Jun 17 2009 - 10:39:26 EDT