Sparx Systems Forum
Enterprise Architect => General Board => Topic started by: GBeutler on September 17, 2010, 09:20:48 pm
-
Hi All,
how can I find out if a class is used as attribute by another class? Relationships and other dependencies can be fond at the element view but I was not able to find anything for usage as attribute there. Thanks in advance and
best regards,
Guido
-
Hello,
although you are asking for some front-end solution I hope the following can help you too:
SELECT * FROM T_ATTRIBUTE a WHERE a.CLASSIFIER = (SELECT o.OBJECT_ID FROM T_OBJECT o WHERE o.EA_GUID='GUID of CLASS');
but this will probably work only if the class as a attribute type was chosen by selecting the class in project tree, I think that if it was written by hand, classifier will not be filled so you will have to search it by name which could not be "precise"
-
This http://community.sparxsystems.com/resources/model-search/search-attributes-type might be a bit easier, although it is name based.
You can easily change that to guid-based if needed.
Geert