Re: Vertical inheritance

From: Julia Filho (jfilho..ahoo.com)
Date: Wed Aug 25 2010 - 16:10:22 UTC

  • Next message: Robert Zeigler: "Re: Vertical inheritance"

    Hi,

    Is vertical inheritance not supported in Cayenne 3.0? According to the
    documentation, vertical inheritance is supported, but I am running into
    problems with the generated SELECT query when reading one of the subclasses:

    The generated query is:

    SELECT t0.DATA_COLLECTION_ID, t0.COLLECTION_TYPE_ID, t0.DATA_COLLECTION_ID,
    t0.SCHOOL_YEAR, t0.SNAPSHOT_DATE FROM ESDM.K12_DATA_COLLECTION t0 JOIN
    ESDM.DATA_COLLECTION t1 ON (t0.DATA_COLLECTION_ID = t1.DATA_COLLECTION_ID)
    JOIN ESDM.DATA_COLLECTION_TYPE t2 ON (t1.COLLECTION_TYPE_ID =
    t2.COLLECTION_TYPE_ID) WHERE t2.COLLECTION_TYPE_ID = ? [bind:
    1->COLLECTION_TYPE_ID:3]

    which is a problem because
    1) column COLLECTION_TYPE_ID is in select list for the subclass
    (K12_DATA_COLLECTION) but that column is in the super class table
    (DATA_COLLECTION), not the subclass
    2) DATA_COLLECTION_ID is in the K12_DATA_COLLECTION select list twice.

    Do you have any suggestions, or is this functionality not yet supported?

    thank you for any assistance you can give
    Julie

    -- 
    View this message in context: http://cayenne.195.n3.nabble.com/Vertical-inheritance-tp827636p1334340.html
    Sent from the Cayenne - Dev mailing list archive at Nabble.com.
    



    This archive was generated by hypermail 2.0.0 : Wed Aug 25 2010 - 18:17:02 UTC