Show Posts

This section allows you to view all posts made by this member. Note that you can only see posts made in areas you currently have access to.


Messages - Ravaa

Pages: [1]
1
Thanks guys, seems the 'where' and '*' were fine, however with a little tweak I've at least managed to get it to produce an error message.

I now get the following error:
Quote
DAO.QueryDef [3135]
Syntax error in JOIN operation.

What do you think?

Really appreciate the support so far!

2
Wow, despite my searches I managed to miss that. Thanks Geert

3
Hi all

Still a Sparx EA newbie so this may be really simple, but is it possible to create a user-defined set of filters to visually filter out classes / relationships in a class diagram?

e.g. user creates 3 filters
  • Show all HR related classes and relationships
  • Show all Finance related classes and relationships
  • Show all Recruitment related classes and relationships
User can select from these, and the wider 'organisation class diagram' filters / greys out those classes / relationships which aren't relevant to these filters

Thanks in advance

4
Just had a chance to play around with this some more, so to clarify...code would look something like this?

Code: [Select]

select a.ea_guid as CLASSGUID,'Attribute' as CLASSTYPE,class.name as Class, class.Note as [Class Description], a.name as Attribute, a.Type,
tv.Property as TagName, tv.VALUE as TagValue,
package.name as [Package Name] ,package_p1.name as [Package level -1],package_p2.name as [Package level -2],package_p3.name as [Package level -3]
from ((((((t_attribute  a
left join t_object class on a.object_id = class.object_id)

left outer join [t_attributetag] v on (v.[ElementID] = att.[ID]
and v.[Property] = 'Versioned')
left outer join [t_attributetag] ts on (ts.[ElementID] = att.[ID]
and ts.[Property] = 'Timesliced')
left outer join [t_attributetag] dc on (dc.[ElementID] = att.[ID]
and dc.[Property] = dc.Value)

left join t_package package on class.package_id = package.package_id)
left join t_package package_p1 on package_p1.package_id = package.parent_id)
left join t_package package_p2 on package_p2.package_id = package_p1.parent_id)
left join t_package package_p3 on package_p3.package_id = package_p2.parent_id)

where a.Name like '*'

Doesn't seem to return anything so I've clearly messed something up - can you please clarify what I'll need to tweak?

5
Thanks Geert, and apologies for late response. I'll work with this and let you know if I have any challenges!

6
Just following up on this, as I wonder if I'm using tagged values appropriately...

My model has the same TagName in all the class elements. I'm wondering if it's possible to modify the above SQL query to have the TagNames return as column heads, with the TagValues returning as values for those column heads for each attribute. Attributes are unique for each class

For example, if class1 has attributes att1, att2...att1 has TagNames tag1 and tag2, as does att2. I want to return tag1 and tag2 as column headers instead of just 'TagName', and have the TagValues for these TagNames return as values for these columns

If not possible, is there something else to capture these common attribute properties instead of tagged values for each of the attributes?

7
Thanks Geert! Much appreciated

8
That's brill, thanks Geert! Does the trick - I use '*' as a search term to show everything as my diagram is fairly small

How about if I have attributes which don't have any tags at all, but I still want to show them in the search results (just with blank tags)?

At the moment they don't show up in the search results

9
Hi folks

I'm currently attempting to obtain a search that provides me the following information:

- Class
- Class description
- Attribute (so 'Class' would repeat for multiple attributes per class)
- Attribute tagged values (so 'Attribute' and 'Class' would repeat for multiple tagged values per attribute)

I've had a look at Geert's 'favourite SQL queries', and figured the SQL query below is probably the closest I can get to the above - however my SQL knowledge is almost non-existent so not sure how to expand to include the above. Can someone please assist?

Code: [Select]
select a.ea_guid as CLASSGUID,'Attribute' as CLASSTYPE,a.name as Name, a.Type as 'Type',  class.name as 'Class Name'
,package.name as 'Package Name' ,package_p1.name as 'Package level -1',package_p2.name as 'Package level -2',package_p3.name as 'Package level -3'
from (((((t_attribute  a
inner join t_object class on a.object_id = class.object_id)
inner join t_package package on class.package_id = package.package_id)
left join t_package package_p1 on package_p1.package_id = package.parent_id)
left join t_package package_p2 on package_p2.package_id = package_p1.parent_id)
left join t_package package_p3 on package_p3.package_id = package_p2.parent_id)
where a.Name like '#WC#<Search Term>#WC#'


Pages: [1]