Re: New objects break FK constraints

From: Arndt Brenschede (a..iamos.de)
Date: Thu Jan 29 2004 - 12:51:59 EST

  • Next message: Mike Kienenberger: "Re: equivalent of DbAttribute.isMandatory() for Relationship?"

    Hi,

    I'm having a similar problem
    (the sorting normally works, but
    e.g. not for reflexive relations,
    because the sorting sorts only the
    tables, not the rows within a table.

    What I wanted to try is to use
    the "DEFERRED" mode of the constraint,
    where it is checked at commit time,
    not at update time.

    If that works, sorting isn't relevant
    anymore.

    If someone tries that and it works,
    could he send me a note

    thanx,

    Arndt

    Andrus Adamchik wrote:

    > Ordering of operations has been around for a while and proved to be very
    > stable. I am fairly sure there is something with the mapping of the
    > relationship (DB constraints and Cayenne mapping do not match). Is this
    > the case described here:
    > http://objectstyle.org/jira/secure/ViewIssue.jspa?key=CAY-41
    >
    > Andrus
    >
    > On Jan 29, 2004, at 11:24 AM, Jim Menard wrote:
    >
    >> I have two objects, BillAccount and Member. Member has a FK to
    >> BillAccount. When I create both objects and try to commit them, I see
    >> a foreign key constraint violation.





    This archive was generated by hypermail 2.0.0 : Thu Jan 29 2004 - 12:51:57 EST