CayenneModeler "To Dep PK" Checkbox problem

From: Rashid Khan (rashidk..mail.com)
Date: Sun Jun 18 2006 - 06:11:46 EDT

  • Next message: Andrus Adamchik: "Re: CayenneModeler "To Dep PK" Checkbox problem"

    Hello there,

    I am using Cayenne1.2RC1. I am facing problems with the CayenneModeler "To
    Dep PK" checkbox.

    I have the following database set up:

    * User table
    * Group table
    * UserGroup table (join table: maps users to groups)

    From what I understand the way cayenne works, I have to check the "To Dep
    PK" checkbox in the UserGroupArray relationship of the User db-entity (and
    the same with the UserGroupArray relationship of the Group db-entity).
    However, the checkbox in the Modeler is disabled.

    When I manually edit the dataMap.map.xml file to set the
    "toDependentPK=true" for the respective relationships, my application works
    fine. But a problem occurs when I open the cayenne.xml file again in the
    modeler.

    Initially, the "To Dep PK" checkbox shows checked as I specified manually in
    the map.xml file. However, when I save the cayenne.xml file again, the
    "toDependentPK=true" gets erased from the map.xml file and, as a result, I
    don't see the "To Dep PK" checkboxes checked anymore in the Modeler.

    Please tell me what is the workaround for this, as it is very critical for
    me to set up the relationships correctly.

    Sincerely,

    Rashid Khan



    This archive was generated by hypermail 2.0.0 : Sun Jun 18 2006 - 08:49:23 EDT