Sparx Systems Forum

Enterprise Architect => Suggestions and Requests => Topic started by: Uffe on May 01, 2009, 05:30:05 pm

Title: Advanced Element Searches
Post by: Uffe on May 01, 2009, 05:30:05 pm
Hi all,


EA is a great modelling tool, but in order to boost productivity even further I'd like to see more higher-order functions in there to help you with maintenance, rather than development, of your models. The company I work for has a couple hundred programmers and product lifecycles which run for decades, so maintenance is the big issue for us.
Here are some suggestions.

Find Externally Connected Elements
Searches a package for elements which have a connector to an element outside the package.
Options: External Target, External Source, Both.
This would help you keep track of what is a purely subsystem-internal concern and what affects other parts of the system.

Find Unused Elements
Searches a package for elements which have no connectors at all, and which are not used as types in attributes, operation parameters, etc.
This is similar to dead code elimination and helps you get rid of things that have been rendered obsolete by the ravages of time.

Find Unconnected Elements
Searches a diagram for elements which have no visible connectors to anything else in the same diagram.
This helps keep your diagrams clean when you make changes in the model.

Comments?


/Uffe
Title: Re: Advanced Element Searches
Post by: Geert Bellekens on May 04, 2009, 05:02:54 pm
Uffe,

Using the SQL editor you can define those searches yourself.
I've found the SQL editor very helpfull in creating advanced searches specific for our modelling method.

Geert
Title: SQL query in document template
Post by: michielper on July 21, 2016, 05:36:42 pm
I am looking for a way to include the (names of) elements connected to a particular element in an RTF document. I suspect this can be done by including an SQL query in the document template but 1. What should that query look like and 2. How do I include a query in a document template.

Any help is appreciated!
Title: Re: Advanced Element Searches
Post by: PeterHeintz on July 21, 2016, 11:15:15 pm
Information about that you find here:
http://www.sparxsystems.com/enterprise_architect_user_guide/12.1/report_generation/custom_sql_fragments.html
Title: Re: Advanced Element Searches
Post by: michielper on July 21, 2016, 11:41:31 pm
OK, PeterHeintz, I will try this!  :)
With another query of course. Is there a collection of example queries somewhere?
Title: Re: Advanced Element Searches
Post by: PeterHeintz on July 22, 2016, 01:03:55 am
Here you find some: https://bellekens.com/tag/search/
If you have MS Access on hand, you can open a eap File = MS Access DB to get an inpression how the things are stored in a DB.
Title: Re: Advanced Element Searches
Post by: qwerty on July 22, 2016, 05:49:03 am
Ctrl-F
Click the Paper-icon left of the red X on top roght
Choose Find Package (and others from the top middle drop down - it shows Simple Search)

There are different pure SQL queries.

q.
Title: Re: Advanced Element Searches
Post by: michielper on July 25, 2016, 08:24:22 pm
 :) It works now, using a fragment I created on the basis of Behavioural Incoming Relationships.

So this is my template:

package > package element >
{PkgElement.Name}
< package element element >
{Element.ParentPackage}
{Element.Name}
Afgeleid uit:
{Template - MP_Incoming}
Toelichting:
{Element.Notes}
child elements > < child elements
< element
child packages > < child packages
< package

And the fragment MP_Incoming is:

package > element > connector > source > element >
{Element.Type} : {Element.Name}
< element < source < connector < element < package

Simple once you know how to do it..... :-)