Small contribution

From: Fabricio Voznika (fabricio.voznik..artmouth.EDU)
Date: Thu Aug 14 2003 - 11:34:38 EDT

  • Next message: Holger Hoffstätte: "Re: Small contribution"

    Hi,

        I spent some time trying to find what primary was missing. I guess
    this message will help finding the problem.

    Index: PrimaryKeyHelper.java
    ===================================================================
    RCS file:
    /home/cvs/3pp/cayenne/cayenne-1.0rc1/src/cayenne/org/objectstyle/cayenne/access/util/PrimaryKeyHelper.java,v
    retrieving revision 1.1
    diff -u -r1.1 PrimaryKeyHelper.java
    --- PrimaryKeyHelper.java 23 Jul 2003 14:19:46 -0000 1.1
    +++ PrimaryKeyHelper.java 14 Aug 2003 15:30:18 -0000
    ..-229,7 +229,7 @@
                            DataObject targetDo =
                                    (DataObject)
    dataObject.readPropertyDirectly(rel.getName());
                            if (targetDo == null)
    - throw new CayenneException("Null master
    object, can't create primary key.");
    + throw new CayenneException("Null master
    object, can't create primary key for: "+dataObject.getClass()+" -
    "+dbRel.getName());
     
                            ObjectId targetKey = targetDo.getObjectId();
                            Map idMap = targetKey.getIdSnapshot();

    Cheers,

    -- 
    Fabricio Voznika
    Senior Programmer/Analyst
    Administrative Computing
    Dartmouth College
    Phone: 603-646-2007
    



    This archive was generated by hypermail 2.0.0 : Thu Aug 14 2003 - 11:28:24 EDT