Author Topic: Merging Elements  (Read 5231 times)

OpenIT Solutions

  • EA User
  • **
  • Posts: 555
  • Karma: +9/-1
    • View Profile
Merging Elements
« on: August 26, 2011, 06:27:21 pm »
Hi,

Coud i request a feature - the ability to merge two or more elements into a single element. I provide governance around models and often find on global projects that individuals wil create duplicate elements in different parts of a model - say the same Component under different packages - EA lacks a feature to merge these into a single component. It would be nice if regular expersions could be used to find/match elements for merging and if one of the elements could be picked as the target.

Thanks,

Jon.

qwerty

  • EA Guru
  • *****
  • Posts: 13584
  • Karma: +396/-301
  • I'm no guru at all
    • View Profile
Re: Merging Elements
« Reply #1 on: August 26, 2011, 09:05:27 pm »
Though I think this would be a good feature I doubt we can get it. What can be done is the following:

  • Have a diagram somewhere in a temp area of the model. Name it Merge so it's clear what its purpose is.
  • Drag all of the duplicates onto the diagram and call Add/Related Elements for each.
  • Auto-layout and start copy/paste notes and drag relations as desired.
  • Issue a Ctrl-U for each element to see their context and clean them individually (that is: replace the duplicate).
  • Remove the duplicate when all its relations are cleared.
  • Clean the merge diagram.
If you look onto that process you will easily find out that an automated support is merely impossible.

q.
« Last Edit: August 26, 2011, 09:08:08 pm by qwerty »

OpenIT Solutions

  • EA User
  • **
  • Posts: 555
  • Karma: +9/-1
    • View Profile
Re: Merging Elements
« Reply #2 on: August 30, 2011, 08:53:41 pm »
Um. I'd still like to request it as a new feature. It seems to me that something like the following sql should work...(in this example to merge object_id 164 into 156)

begin
delete from t_object where object_id = 164;
update t_diagramobjects set object_id = 156 where object_id = 164;
update t_attribute set object_id = 156 where object_id = 164;
update t_attributeconstraints set object_id = 156 where object_id =164;
update t_method set object_id = 156 where object_id = 164;
update t_objectconstraint set object_id = 156 where object_id = 164;
update t_objecteffort set object_id = 156 where object_id = 164;
update t_objectfiles set object_id = 156 where object_id = 164;
update t_objectmetrics set object_id = 156 where object_id = 164;
update t_objectproblems set object_id = 156 where object_id = 164;
update t_objectproperties set object_id = 156 where object_id = 164;
update t_objectrequires set object_id = 156 where object_id = 164;
update t_objectresource set object_id = 156 where object_id = 164;
update t_objectrisks set object_id = 156 where object_id = 164;
update t_objectscenarios set object_id = 156 where object_id = 164;
update t_objecttests set object_id = 156 where object_id = 164;
update t_objecttrx set object_id = 156 where object_id = 164;
update t_operation set object_id = 156 where object_id = 164;

update t_connector set start_object_id = 156 where start_object_id = 164;
update t_connector set end_object_id = 156 where end_object_id = 164;
commit;

Eve

  • EA Administrator
  • EA Guru
  • *****
  • Posts: 8085
  • Karma: +118/-20
    • View Profile
Re: Merging Elements
« Reply #3 on: August 31, 2011, 08:36:54 am »
Missing... Classifiers for objects (also by guid), attributes, operations, parameters.
Parent ids for both diagrams and objects.
Tagged value references (by guid), xref references (by guid)

That's really just a start, there are also special cases such as association classes etc.

skiwi

  • EA Expert
  • ****
  • Posts: 2081
  • Karma: +46/-82
    • View Profile
Re: Merging Elements
« Reply #4 on: August 31, 2011, 01:18:32 pm »
I'd vote for this,
it would be a 'killer' feature for model maintenance
Orthogonality rules
Using EA16.1 (1627) on Windows 11 Enterprise/64 bit. Repositories in SQLServer2019 DB Schema 1558.
WebEA on Pro Cloud Server 4.2.64

OpenIT Solutions

  • EA User
  • **
  • Posts: 555
  • Karma: +9/-1
    • View Profile
Re: Merging Elements
« Reply #5 on: August 31, 2011, 07:34:45 pm »
Hi Simon,

Thanks for the input. yep your right of course. i derived the sql by scanning the ddl used to create the ea model for occurances of object_id - appreciate that without your inpt i'd probably end up doing more harm than good...hence the request for this to be added as a feature - for those of us managing large models/teams it would be gold dust!

Thanks again,

Jon.

qwerty

  • EA Guru
  • *****
  • Posts: 13584
  • Karma: +396/-301
  • I'm no guru at all
    • View Profile
Re: Merging Elements
« Reply #6 on: September 01, 2011, 06:55:01 am »
Quote
I'd vote for this,
it would be a 'killer' feature for model maintenance
If you mean it would kill your model I' be with you. Just think about what Simon said.

q.