Jazz Forum Welcome to the Jazz Community Forum Connect and collaborate with IBM Engineering experts and users

Counting links for requirement in JRS using LQE

 Hi all,


Currently I have to count links of a requirements in DNG using JRS report builder (LQE mode) as link_count column
I have added 1 column to the report, call status_link for example
Based on the links counted for every requirement, I have to classify requirement and fill the value to status_link column.
For example:
- If there is no links in the requirement, then status_link value would be "Not Linked"
- If there is at least 1 link or more, then status_link value would be "Linked"

By using SPARQL Query (advanced mode on JRS), I have added status_link column to the JRS report successfully, but I have no idea how to perform condition checking as described above

Can you please help me on that?

Thank you,
Best regards,
Anh Do

0 votes



One answer

Permanent link

Hi Anh Do,

I have never created similar SPARQL query before, but here is my rough idea.

In the latest version of JRS, there is a feature to create a requirement list which do not have links by using "Enable multiple paths or add other source artifacts", and adding all type of links one by one.


The above setting will create filters like below.

FILTER NOT EXISTS {
    ?oslc_rm_Requirement2_uri xmlns_rdm_types:Embedding ?oslc_rm_Requirement1_uri.
    ?oslc_rm_Requirement2_uri rdf:type oslc_rm:Requirement.
  }
...
FILTER NOT EXISTS {
    ?oslc_rm_Requirement3_uri oslc_rm:constrainedBy ?oslc_rm_Requirement4_uri.
    ?oslc_rm_Requirement4_uri rdf:type oslc_rm:Requirement.
  }

You can consolidate multiple "FILTER NOT EXISTS" into one. Perhaps you can manipulate this query result to make it a condition checking.

0 votes

Comments

If you don't mind using Data warehouse, "All link types" is available, and calculation is much simpler. 

Your answer

Register or log in to post your answer.

Dashboards and work items are no longer publicly available, so some links may be invalid. We now provide similar information through other means. Learn more here.

Search context
Follow this question

By Email: 

Once you sign in you will be able to subscribe for any updates here.

By RSS:

Answers
Answers and Comments
Question details
× 360
× 73
× 25

Question asked: Aug 29 '17, 6:51 a.m.

Question was seen: 1,949 times

Last updated: Aug 31 '17, 2:14 a.m.

Confirmation Cancel Confirm