Re: help on saving obj using relations

From: Michael Gentry (blacknex..mail.com)
Date: Thu Apr 17 2008 - 11:46:54 EDT

  • Next message: Mauro Carniel: "Fw: help on saving obj using relations"

    I looked at:

    http://oswing.svn.sourceforge.net/viewvc/oswing/trunk/srcdemo/demo36/auto/_EmpVO.java?revision=214&view=markup

    And I don't believe you have modeled your relationships correctly.
    You manually created a get/setDept() and get/setTask() in the
    subclass:

    http://oswing.svn.sourceforge.net/viewvc/oswing/trunk/srcdemo/demo36/EmpVO.java?revision=214&view=markup

    However, those should be generated by Cayenne in the parent
    (_EmpVO.java) class. At least if you have your relationships modeled
    correctly. Go back into the modeler and look under the Relationship
    tab for both your DbEntity and your ObjEntity and make sure they are
    defined in each place. You may need to synchronize your ObjEntity
    with your DbEntity (click the sync button). After you get your
    relationships defined, regenerate your superclasses.

    /dev/mrg

    On Thu, Apr 17, 2008 at 11:03 AM, Gustav Weber <gustav_weber7..ahoo.com> wrote:
    > I guess Mauro forgot to mention an important aspect:
    >
    > The situation appeared while integrating Cayenne with
    > OpenSwing:
    > http://oswing.sourceforge.net/
    >
    > and the problem he describes can be seen/reproduced
    > from the code example in "srcdemo/demo36" from the
    > project's Sourceforge SVN repository:
    > http://sourceforge.net/projects/oswing/
    >
    > regards,
    > Gustav.
    >
    >
    >
    > ____________________________________________________________________________________
    > Be a better friend, newshound, and
    > know-it-all with Yahoo! Mobile. Try it now. http://mobile.yahoo.com/;_ylt=Ahu06i62sR8HDtDypao8Wcj9tAcJ
    >
    >



    This archive was generated by hypermail 2.0.0 : Thu Apr 17 2008 - 11:47:26 EDT