Author Topic: Link attribute to Business Rule  (Read 3823 times)

ruby.redcar

  • EA Novice
  • *
  • Posts: 4
  • Karma: +0/-0
    • View Profile
Link attribute to Business Rule
« on: September 22, 2010, 02:35:09 pm »
Hi Folks I'm a relatively new user to EA.   I'm currently contructing a model that I would like to link business rules to.   I have been successful in linking business rules to entities - tables and classes, however, wonder if it is possible to link a business rule to an attribute.  This way I can report all the attributes (and therefore tables) that a business rule requires.    

The next part of the question once I have been successful in linking business rules to attributes, how can I report the outcomes using the inbuilt reporiting features of EA.  

In summary, what we are trying to achieve is to select a business rule and determine which attributes of which table use it; and select an attribute and determine which business rules rely on it.  

I look forward to your advice.
« Last Edit: September 22, 2010, 02:55:50 pm by ruby.redcar »

Geert Bellekens

  • EA Guru
  • *****
  • Posts: 13295
  • Karma: +557/-33
  • Make EA work for YOU!
    • View Profile
    • Enterprise Architect Consultant and Value Added Reseller
Re: Link attribute to Business Rule
« Reply #1 on: September 22, 2010, 03:12:05 pm »
Ruby,

There are two ways of relating an attribute to an element (business rule in this case)
- Use the 'link to element feature' on a relation between the business rule and the owner of the attribute
- Use a tagged value with type 'RefGUID' or 'RefGUIDList'.

Link to element feature doesn't require any setup or configuration, but it is harder to use the actual link in addins or (i guess) RTF reports, and the sheer number of relations might be a bit too much.

I would use the tagged value approach.

Geert


ruby.redcar

  • EA Novice
  • *
  • Posts: 4
  • Karma: +0/-0
    • View Profile
Re: Link attribute to Business Rule
« Reply #2 on: September 23, 2010, 12:24:00 pm »
Geert

Thanks for your response.  I;m so new at this that whilst I'm aware of these options I haven't used them.   I'll do some research and come back to you to let you know the outcome.

Thanks again for your assistance.

Ruby

Agecoat

  • EA Novice
  • *
  • Posts: 11
  • Karma: +0/-0
    • View Profile
Re: Link attribute to Business Rule
« Reply #3 on: September 28, 2010, 12:07:24 am »
Geert,

Could you be a bit more specific about the constructions?

Although not entirely the same construction, I want to create traces between a realization level element and a semantical level element.

In general:

- I want to free the semantical level from realization details; attributes will have business names.
- I want to be flexible in realization details; atributes will have technical names
- I want to trace realization level to semantical level

In particular:

- A class in semantical level with attributes in it
   - Attributes named according to business
- A class in realization level with attributes in it
   - Attributes named according to particular XML-tag naming convention
- A trace between realization level attribute and semantical level attribute

The problems:

- EA (8.0.858) is not consistent in connecting the attributes with a trace. Often the, selection of element feature results in linking the name of the element itself i.s.o. the specified element attribute
- The element links are very hard to alter; getting the context menu for the right trace seems cumbersome.
- This level of detail seems only a visual aid.

The questions:

- are we talking EA-bug here or is it a feature I don't know of?
- is there another way to alter the element links than by context menu on a trace end?
- how do I get to change the type of a tagged value? Only through stereotyping the element?
- is there a favourable way of doing traceability between said layers and this level of detail?

Thx'nAdv.

Agecoat
« Last Edit: September 28, 2010, 12:11:40 am by Agecoat »
Using EA Corporate 8.0.863

Geert Bellekens

  • EA Guru
  • *****
  • Posts: 13295
  • Karma: +557/-33
  • Make EA work for YOU!
    • View Profile
    • Enterprise Architect Consultant and Value Added Reseller
Re: Link attribute to Business Rule
« Reply #4 on: September 28, 2010, 03:28:43 pm »
Agecoat,

The "link to element" feature indeed doesn't seem like the right tool to use for attribute traceability.
Instead I would use tagged values.
You can define standard tagged values with type RefGUID or RefGUIDList. If you define a tagged value like that you can select a (list of) UML element  from your model as the value of the tagged value.
If you want to do it properly then indeed you will need to create a profile, define a stereotype, and attach the tagged value to the stereotype. But EA will also allow you to define just the tagged value as well. (but then you'll have to add it manually to each attribute)

Look here : http://www.sparxsystems.com/enterprise_architect_user_guide/modeling_languages/predefinedtaggedvaluetypes.html for more details about defining tagged values.

Geert


Frank Horn

  • EA User
  • **
  • Posts: 535
  • Karma: +1/-0
    • View Profile
Re: Link attribute to Business Rule
« Reply #5 on: September 28, 2010, 05:39:45 pm »
Quote
If you want to do it properly then indeed you will need to create a profile, define a stereotype, and attach the tagged value to the stereotype. But EA will also allow you to define just the tagged value as well. (but then you'll have to add it manually to each attribute)

Geert,

if you define an attribute stereotype with a tagged value in a profile (within an MDG technology): when will the tagged value ever be automatically added to an attribute? You cannot drag an attribute from the toolbox, you have to add it via dialog, and within the dialog choose the stereotype. But EA will not add any tagged values then, and synchronization works from a toolbox context menu only.

So tagged values on profile attribute stereotypes are completely useless (same with operations, association ends, parameters a.s.o.). Or did you find a way to make it work?

As to RefGUID tagged values of various type: you can only set them if the type is something listed in the project browser. So it will work for attributes and operations, but not for associations or association ends.

Geert Bellekens

  • EA Guru
  • *****
  • Posts: 13295
  • Karma: +557/-33
  • Make EA work for YOU!
    • View Profile
    • Enterprise Architect Consultant and Value Added Reseller
Re: Link attribute to Business Rule
« Reply #6 on: September 29, 2010, 03:20:41 pm »
Frank,

I've never played around with the MDG stuff, so I definitely haven't found a solution for the element feature tagged values.
I guess you could cook up something with an addin if you really need it..

Geert

ruby.redcar

  • EA Novice
  • *
  • Posts: 4
  • Karma: +0/-0
    • View Profile
Re: Link attribute to Business Rule
« Reply #7 on: September 29, 2010, 05:26:37 pm »
Thank you to everyone who has contributed.   We have made some headway, well cooked something.

Actually we used the Link to Element Feature.     We selected the target element as the table (the source was the  Business Rule).    The feature type selected was Attribute and the Feature was the required attribute.    

The diagram produced is rather nice.  

We then created and RFT report which almost meets our needs, but is not exactly as flexible or pretty as we would like.    Is it possible to extract/view the SQL used to create the report.  

Our next process was to go to the database and try to extract our own dataset to create exactly what we need to present.  
I have gotten as far as
  • determining the start and end objects, ie the business rule and the table that it relates to.  

Ihave also identified the connector and the instance id related, together with the package of the source and destination objects.
I can link the attributes to the end object (ie the table that contains the attributes that the business rule is linked to.
However,   I cannot limit or link the connector_Id directly with the attribute, therefore returning only the attributes that are linked to the business rule.  
What I need is a table/query that contains   connectorId and attribute id which will enable me to link attribute information with connection information.      
[/list]  

Can anyone provide any how to on this?  

I'm thinking that if I can see the sql behind the report then I will be able to find the link.  

I look forward to your advice.

Regards

Ruby