Book a Demo

Author Topic: rerunning model transformations  (Read 3352 times)

Peter Parslow

  • EA Novice
  • *
  • Posts: 11
  • Karma: +0/-0
    • View Profile
rerunning model transformations
« on: January 26, 2010, 10:34:40 pm »
Hi,
I like the way that I can re-run a model transformation, and EA attempts to only change the bits in the target (DDL, in my case) that I've changed in the source (UML class diagram).

But, sometimes it doesn't work. Particularly, I needed to introduce role names, because the constraint names generated automatically can be too long for Oracle. Redoing the transform creates the new foreign keys, but doesn't delete the old ones. I can't delete the old ones in the DDL package, because they are foreign keys. So I deleted the relevant tables in the DDL package and re-run the model transfomr again.

Now the new table doesn't get joined to the parent, and gets no foriegn key at all. The only solution seems to be to delete the whole target package and re-run the transform from scratch. Shame.

Oliver F.

  • EA User
  • **
  • Posts: 573
  • Karma: +2/-1
  • ArenĀ“t we all in the model business ?
    • View Profile
    • Karl Storz homepage
Re: rerunning model transformations
« Reply #1 on: January 26, 2010, 11:13:34 pm »
My experience shows a rather similar picture. In fact I  have to remove the whole folder with all tables including the diagram and rerun the transformation to get an updated result.
Even if the tables alone are removed does not seem to bring sufficient success- all subsequent transformation results are showing no connectors (and therefore foreign keys). Removing the corresponding package diagram seems to help in this case.
The same can be seen when transforming classes which have not been tranformed before if there are classes (and diagram) available from a previous transformation.

I got used to this behavior though new team members will be rather confused.

Oliver


dannodj

  • EA Novice
  • *
  • Posts: 18
  • Karma: +0/-0
    • View Profile
Re: rerunning model transformations
« Reply #2 on: January 27, 2010, 03:21:45 am »
I also have the same experience, which is frustrating because there are some properties of the PSM which can't automatically be derived from the PIM.  In my case the Navigability of associations needs to be set manually to determine the hierarchy structure of an xml schema.

It seems that the transform overwrites certain properties in the target model, e.g. role names on associations, but doesn't care about how Navigability is set in the target model.  

This seems odd because the Transform Templates are usually set up to transfer all properties, unless specified otherwise.  I wonder whether the transform templates can be coded to explicitly take into account any changes you make in the target model?

Have either of you got anywhere with sparx support?
Dan