How to query RDNG artifacts base on their type?
Hi. I am using Jazz Team Server Location Version 6.0.1 M2 and I tries to query artifacts base on their type using REST API on the Server but I cat make the right URI.
I get the base URI:
baseURL=https://<ip>:<port>9443/rm/views?oslc.query=true&projectURL=https%3A%2F%2F<ip>%3Aport%2Frm%2Fprocess%2Fproject-areas%2F_Agw1YEA_EeW98vRsdfPEQ
so to make the query I have to append the filter. First I get the type base on the instanceShape:
<oslc:instanceShape rdf:resource="https://<ip:port>/rm/types/_opYnsUasdL2aNIq4SA-w"/>
and construct the filter
&oslc.prefix=rm=http://www.ibm.com/xmlns/rdm/rdf/&oslc.select=*&oslc.where=rm:ofType=https://<ip:port>/rm/types/_opYnsUasdL2aNIq4SA-w
And the final get is:
baseQuery+filter
https://<ip>:<port>9443/rm/views?oslc.query=true&projectURL=https%3A%2F%2F<ip>%3Aport%2Frm%2Fprocess%2Fproject-areas%2F_Agw1YEA_EeW98vRsdfPEQ&oslc.prefix=rm=http://www.ibm.com/xmlns/rdm/rdf/&oslc.select=*&oslc.where=rm:ofType=https://<ip:port>/rm/types/_opYnsUasdL2aNIq4SA-w
But nothing happens? Where is my mistake?
Accepted answer
I suggest you read the below article carefully as it has the exact sample.
https://jazz.net/library/article/1197
Both the "rm:ofType" and "oslc:instanceShape" filters work for me on RNDG 5.0.2 and 6.0. The complete OSLC query filter (appending to the base URL) should look like
Not quite sure whether it is the forum messing up your post, but your URL appears to be missing the angle brackets for both "oslc.prefix" and "olsc.where".
https://jazz.net/library/article/1197
Both the "rm:ofType" and "oslc:instanceShape" filters work for me on RNDG 5.0.2 and 6.0. The complete OSLC query filter (appending to the base URL) should look like
Not quite sure whether it is the forum messing up your post, but your URL appears to be missing the angle brackets for both "oslc.prefix" and "olsc.where".