Re: prefetching

From: Andrus Adamchik (andru..bjectstyle.org)
Date: Tue Dec 09 2003 - 11:22:59 EST

  • Next message: James Treleaven: "Re: Accessing PK and FK values of DataObjects"

    Yeah, there are some limitations when prefetching on relationships
    defined one way. In case of lookup entities though, using a shared
    DataContext pattern is probably a better solution anyway (it is briefly
    mentioned here:
    http://objectstyle.org/cayenne/userguide/datactxt/moving-objects.html )
    - it will save a database trip for prefetch query.

    Andrus

    On Dec 9, 2003, at 9:57 AM, Tore Halset wrote:

    > Hello!
    >
    > I have a database with db-relationships like:
    >
    > person<<-->gender
    > person<<-->favorite color
    > person<<-->hairstyle
    >
    > The obj-relationships look like
    >
    > person-->gender
    > person-->favorite color
    > person-->hairstyle
    >
    > I have a SelectQuery with an Expression to query for some persons. I
    > want to prefetch in the lookup-tables for gender and hairstyle.
    >
    > Everything works if the obj-relationships are defined both ways, but I
    > do not want to define them both ways. Am I doing something wrong? Is
    > this a cayenne bug?
    >
    > - Tore.
    >
    >



    This archive was generated by hypermail 2.0.0 : Tue Dec 09 2003 - 11:23:08 EST