Why is OSLC Query in Rational Team Concert not returning the expected result when I pass in specific parameters?
However, when I pass in additional parameters, it does not work as expected.
1) If I append &oslc.select=* or &oslc.select=dcterms:title to it, I do not get back any additional properties. From what I understood, &oslc.select=* is supposed to give back all the properties and &oslc.select=dcterms:title is supposed to give back the title of the work item. What did I do wrong with oslc.select?
2) Suppose I don't know the type of link, so I replaced oslc_cm:tracksChangeSet with *. It doesn't work and gives the error: Unknown attribute id [*]. What is the correct syntax?
3) In the OSLC query spec at http://open-services.net/bin/view/Main/OSLCCoreSpecQuery, I am supposed to be able to add or oslc_cm:tracksChangeSet=<https://myserver/changesetId2> to the above. But that gives an error. What is the correct way to use or?
Accepted answer
https://oslcqueryurl/workitems
https://oslcqueryurl/workitems?oslc.select=dcterms:title&oslc.prefix=dcterms=%3Chttp%3A//purl.org/dc/terms/%3E
https://oslcqueryurl/workitems?oslc.where=cm:severity in ["high","medium"]&oslc.select=oslc_cm:severity
Comments
If operating in the OSLC v2 space, shouldn't we be asked for the query base resource and using that, e.g. (example taken from RM but same idea):
/rm/views?oslc.query=true&projectURL=https%3A%2F%2Frtc.jpmchase.net%3A9443%2Fjts%2Fprocess%2Fproject-areas%2F_Z__esDcNEeGHKNXfHpevWg&oslc.prefix=dc=<http://purl.org/dc/terms/>&oslc.where=dc:title="ABC"'
Whoops. If you oslcqueryurl means the URL at the queryBase then I get it. CCM and QM and RM have some web service inconsistencies and I incorrectly assumed oslcqueryurl was yet another means to get at the data (like the Requirements Reporting API)
Thanks for your reply, Jan, and especially for that link to the examples. It gives me a much better understanding of the expected syntax!
A question about the discovery mechanism: I tried
https://servername:port/ccm/oslc/contexts/_projectId/workitems/services.xml and it gives me back an XML document -- how do I tell if * operator is supported?