Book a Demo

Author Topic: Change model element type  (Read 4481 times)

cmpk

  • EA Novice
  • *
  • Posts: 3
  • Karma: +0/-0
    • View Profile
Change model element type
« on: February 20, 2013, 01:38:37 am »
I have a UML component model in which someone represented file input as components and I would like to change those to Artifact elements.  What's the best way to change the element type but keep all associations in the model?

Ian Mitchell

  • EA User
  • **
  • Posts: 507
  • Karma: +22/-4
  • The eaDocX and Model Expert guy
    • View Profile
Re: Change model element type
« Reply #1 on: February 20, 2013, 02:38:07 am »
Main EA menu | Element | Advanced | Change type.
Ian Mitchell, Designer, eaDocX


www.eaDocX.com
www.theartfulmodeller.com

qwerty

  • EA Guru
  • *****
  • Posts: 13584
  • Karma: +397/-301
  • I'm no guru at all
    • View Profile
Re: Change model element type
« Reply #2 on: February 20, 2013, 02:38:36 am »
Try Element/Advanced/Change Type

If you have a lot of element you might think of either writing a script or running a SQL which can do the job.

q.

[edit] Ian was faster with the first suggestion.
« Last Edit: February 20, 2013, 02:40:05 am by qwerty »

Ian Mitchell

  • EA User
  • **
  • Posts: 507
  • Karma: +22/-4
  • The eaDocX and Model Expert guy
    • View Profile
Re: Change model element type
« Reply #3 on: February 20, 2013, 03:10:29 am »
If you really do have lots, then open the package in Excel using eaDocX, then just change all the Elements Types, and (thoughtfully) read them straight back into EA.
Ian Mitchell, Designer, eaDocX


www.eaDocX.com
www.theartfulmodeller.com

Geert Bellekens

  • EA Guru
  • *****
  • Posts: 13523
  • Karma: +574/-33
  • Make EA work for YOU!
    • View Profile
    • Enterprise Architect Consultant and Value Added Reseller
Re: Change model element type
« Reply #4 on: February 20, 2013, 06:00:34 pm »
or you could open up an SQL client and execute something like
Code: [Select]
update t_object set Object_Type = '<new type>'
where <criteria>

Geert

cmpk

  • EA Novice
  • *
  • Posts: 3
  • Karma: +0/-0
    • View Profile
Re: Change model element type
« Reply #5 on: February 20, 2013, 11:02:09 pm »
Thanks everyone.  You've given me the clues I needed.  I managed several fixes with the manual method and then converted a whole model using the SQL route.