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

DNG 6.0 : Fetch requirements from Requirement Collection

I am able to fetch URI of the collection in DNG. i want to get requirements in that collection. I have tried query given in the article (https://jazz.net/library/article/1197) but didn't work. I am using OSLC, Eclipse, java. Thanking in advance.

0 votes

Comments

You'd better clarify what you did and what you got. The word "didn't work" provides no information to work towards a solution.

1 vote

Hi Donald,
I have tried set the prefix and where in my query but got zero result.
Finally, I am able to do that with different approach.  I have done a GET on collectionURI and parse the value of RequirementURI from "oslc_rm:uses" tag.I am able to retrieve all the Requirements in a collection. just want to conform, is my approach correct  ?.

If your goal is get the list of requirements contained in the collection, the easiest way should be just GET the collection URL. Still not exactly sure what you did though.

1 vote

Thanks for response,
for now i need only list of requirements and as you said GET is also right way so i will go with this since i have already done by this approch.

my requirement was, i wanted to get list of all the requirements in a folder where i have folder URI. i have written query to get the URI of all the requirements(artifacts) in the folder.
I was able to get all the requirements until there is no collection in the folder. if there is one or more collection then i start getting exception since i was treating every URI as requirement in folder.
I have stored all the requirements in List and List of the Collections URI in other List.
then start pulling out the requirements from collection(s) one by one and adding it into the Requirements list. By this way i am able to get all the requirements in a folder and also requirements from the collection in the folder. I don't know if there is other simple way to do this.

Since your requirement is very specific, I think that is the best you can do.

1 vote


Be the first one to answer this question!

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
× 10,938

Question asked: Sep 27 '15, 11:50 p.m.

Question was seen: 2,279 times

Last updated: Sep 28 '15, 11:53 p.m.

Confirmation Cancel Confirm