cayenne-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Tore Halset <>
Subject Re: CayenneModeler and Reengineering Database Schema
Date Tue, 27 Nov 2007 14:26:58 GMT

I think this is handled by the merge-stuff I have worked on. It will  
be included in the next 3.0 milestone.

  - Tore.

On Nov 26, 2007, at 23:06 , Michael Lepine wrote:

> Hello all.
> I am currently using CayenneModeler version 2.0.3 to reengineer a
> database schema and generate the subsequent Java classes. Some of the
> ObjEntity instances have primary/foreign keys mapped manually because
> these keys are generated by another process (outside of the Cayenne
> framework). The schema that I manage is very large and is periodically
> updated as part of maintenance and new development tasks. In order to
> update the model ( file) with the schema changes, I go
> through a fairly tedious process that involves the following:
> 1. update database schema
> 2. copy cayenne configuration files (cayenne.xml, and
> ...driver.xml) to a temp directory
> 3. start CayenneModeler
> 4. open the project from the temp directory
> 5. run Tools > Reengineer Database Schema
> 6. when prompted that a table exists, I opt to overwrite it to ensure
> I get all updates
> 7. save (temp) project
> 8. compare the differences between the temp map.xml and original
> map.xml files, manually copying the updates from the original to the
> temp file
> 9. test that I haven't made mistakes by opening the temp project and
> then double-checking it visually if it loads
> I do this because the manual mappings in the ObjEntity instances are
> removed when I run Reengineer Database Schema which does not seem like
> desired behavior. I would expect manual attribute mappings created in
> the ObjEntity instances to remain after reengineering a schema if:
> 1. the same schema is being reengineered
> 2. the corresponding DbEntity attribute still exists
> I downloaded the 2.0.4 and 3.0M2 versions of the Modeler to see if the
> behavior was different. It appears that manually mapped ObjEntity
> attributes are dropped in all versions under the above scenario.
> Is there an easier/more efficient way to update my model (map.xml)  
> files?
> Has anyone else encountered a similar issue?
> Thank you for your help.
> - Mike

View raw message