Compound ObjEntity Status

From: Andriy Shapochka (ashapochk..otmail.com)
Date: Tue Mar 04 2003 - 16:11:05 EST

  • Next message: Andrus Adamchik: "Re: ObjRelationship isToMany"

    Read only compound ObjEntities are implemented and tested at the basic level. Please see an example of such an entity and work with it in src/tests/resources/test-resources/testmap.map.xml (CompoundPainting), also, CompoundPainting.java in the art subpackage, and org.objectstyle.access.DataContextCompoundOETst.java (in tests). As, generally speaking, we cannot rely on DbAttribute names as keys in row maps ResultSets are converted into anymore, entire dbAttributePaths stored in ObjAttributes are used for this purpose. If a path is not found or there is no matching ObjAttribute the implementation falls back to a DbAttribute name. For regular ObjEntities nothing is changed since dbAttributePath == dbAttributeName for them. As it was stated in the spec earlier inner joins are presently used to aggregate values from several tables into a record, SelectQuery being performed. Therefore NULL values of foreign keys and similar things lead to exclusion of the corresponding records. This will probably be tunable to switch between outer and inner joins in the future. Everybody are welcome to try the feature out and find as many bugs as possible :-). Looks like I fixed the pk generation bug found by Holger. At least, Cayenne passes the tests for MySQL and for Oracle. Don't have PostgreSQL installation. Read-write entities will be implemented for ContextCommit/batching version of commit. We are going to switch to it anyway.

    Andriy.



    This archive was generated by hypermail 2.0.0 : Tue Mar 04 2003 - 16:10:23 EST