Re: To Dep PK?

From: Bill Fan (bil..anscom.com.au)
Date: Wed Jan 15 2003 - 06:02:02 EST

  • Next message: Andrus Adamchik: "Re: Transactions"

    Michael,

    I think I could try to explain it from what I just understood from the
    result of my previous thread - 1:n deletion problem.

    If we refer back to this thread, there are Project & ProjectUsers table in
    the database. The related db-relationship and obj-relationship entries from
    the data map xml file are as below:

     <db-relationship name="projectusersArray" source="PROJECT"
    target="PROJECTUSERS" toDependentPK="true" toMany="true">
      <db-attribute-pair source="ProjectID" target="ProjectId"/>
     </db-relationship>

     <obj-relationship name="projectusersArray" source="Project"
    target="Projectusers" toMany="true" deleteRule="Nullify">
      <db-relationship-ref source="PROJECT" target="PROJECTUSERS"
    name="projectusersArray"/>
     </obj-relationship>

    Now the point:
    ==========
    toDependenPK above means the PROJECTUSERS.ProductId value must reference(or
    use) the value of the PROJECT.ProjectId. It represents the FK relationship
    in the database.

    Hope this helps.

    Bill

    ----- Original Message -----
    From: "Michael Schuldt" <m..scensys.de>
    To: <cayenne-use..bjectstyle.org>
    Sent: Wednesday, January 15, 2003 6:48 PM
    Subject: To Dep PK?

    > Hi,
    >
    > could anyone explain what's meant by "To Dep PK" within Cayenne Modeler? I
    > tried to figure out but with no success.
    >
    > Thank you
    >
    > Michael
    >
    >
    >



    This archive was generated by hypermail 2.0.0 : Wed Jan 15 2003 - 05:02:22 EST