OSLC Query for fetching list of Requirements and Testcases based upon modification Date
Hello,
I want to fetch the list of artifacts or Requirements ,Testcases, TestPlan etc ,which has modified today or modified within date range.
I have used oslc_qm.query to filter based upon specific date but it is not returning filtered data.
Kindly guide me, even if it possible through reportable rest API.
I found below query, but I am not able to get exact output by running this query
==>Include all properties of the test plan(s) with an updated property greater or equal to '2016-02-22T20:16:26.928Z' and less or equal to '2017-02-22T20:16:26.928Z'
<feedUrl>?fields=feed/entry/content/testplan[updated>='2016-02-22T20:16:26.928Z' and updated<='2017-02-22T20:16:26.928Z']/*
<feedUrl> -->which url to be replaced by feed url
I have taken reference from:-https://jazz.net/wiki/bin/view/Main/RqmApi#feedUrl_for_interaction_with_a_f
Kindly provide some examples to achieve this either by using oslc or reportable rest API.
Thanks and Regards,
Jyoti
Accepted answer
Hi Jyoti
For DOORS Next and Engineering Test Management (RQM) - use OSLC Query, you can specify oslc.where the "Modified On" attribute (as rdf type uri dcterms:modified) is before/after a date using </> and the date-time as a string e.g. "2021-07-01T21:51:40.979Z"^^xsd:datetime - note for DOORS Next the ^^xsd:datetime is required, seems to be optional for ETM for 6.0.6.1 and 7.0.2
So use e.g.:
- oslc.where=dcterms:modified>"2020-07-01T21:51:40.979Z"^^xsd:datetime
with oslc.prefix including dcterms e.g.
- oslc.prefix=dcterms=<http://purl.org/dc/terms/>
UPDATE:
Here's an example of a fully encoded OSLC query for DOORS Next artifacts modified after 2020-08-01T21:51:40.979Z - note that the Z indicates this is UTC only; other timezones aren't supported.
https://jazz.ibm.com:9443/rm/views?oslc.query=true&projectURL=https%3A%2F%2Fjazz.ibm.com%3A9443%2Frm%2Fprocess%2Fproject-areas%2F_NDNJ0NcLEeqXpuBdEolY7w&oslc.prefix=dcterms%3D%3Chttp%3A%2F%2Fpurl.org%2Fdc%2Fterms%2F%3E%2Crm_nav%3D%3Chttp%3A%2F%2Fjazz.net%2Fns%2Frm%2Fnavigation%23%3E&oslc.where=dcterms%3Amodified%3E%222020-08-01T21%3A51%3A40.979Z%22%5E%5Exsd%3Adatetime&oslc.select=dcterms%3Aidentifier%2Crm_nav%3Aparent&oslc.paging=true&oslc.pageSize=200
Sent with headers (possibly case-sensitive, works capitalized as below):
- OSLC-Core-Version: 2.0
- vvc.configuration: https://jazz.ibm.com:9443/rm/cm/stream/_NMu5RtcLEeqXpuBdEolY7w
- Accept: Application/rdf+xml
Decoding the parameter values and splitting the parameters onto separate lines to make it easier to read, this looks like:
?oslc.query=true
&oslc.prefix=dcterms=<http://purl.org/dc/terms/>,rm_nav=<http://jazz.net/ns/rm/navigation#>
&oslc.where=dcterms:modified>"2020-08-01T21:51:40.979Z"^^xsd:datetime
&oslc.select=dcterms:identifier,rm_nav:parent
&oslc.paging=true
&oslc.pageSize=200
HTH
Ian
Comments
showing 5 of 6
show 1 more comments
2 other answers
I don't know about reportable REST for test plans. However, https://jazz.net/wiki/bin/view/Main/ReportsRESTAPI shows a common modified property. Try using that instead of updated.