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

RQM rest api get Testcase by title with % on the title

Good  morning,
i am using the rest api on RQM 6.0 to get the date of a testCase matching a specific title, but the title contains the % simbol and i could not make the query work.
Lests say the title is "Check that the preasure is under 100%"

Acording to the api documentaiton: https://jazz.net/wiki/bin/view/Main/RqmApi : "wildcard characters may be escaped by a proceeding # character"

So I ran the query like:
.../testcase?fields=feed/entry/content/testcase[title='Check that the preasure is under 100%']/* <-- expected fail: URLDecoder: Illegal hex characters in escape (%) pattern - For input string.

.../testcase?fields=feed/entry/content/testcase[title='Check that the preasure is under 100#%']/* <-- return all the TC regardless of the title

.../testcase?fields=feed/entry/content/testcase[title='Check that the preasure is under 100##%']/* <-- return all the TC regardless of the title

.../testcase?fields=feed/entry/content/testcase[title='Check that the preasure is under 100\%']/* <-- fails: URLDecoder: Illegal hex characters in escape (%) pattern - For input string

.../testcase?fields=feed/entry/content/testcase[title='Check that the preasure is under 100\\%']/* <-- fails: URLDecoder: Illegal hex characters in escape (%) pattern - For input string

i also tried all this combination replacing the string char ' to " with similars results

Also tried adding &wildcard=X 
but it does not work.

I dont know what else to try, but it fails or return everything regardles of the title.
Any clue on how to escape the % character

0 votes



One answer

Permanent link
Hello Pablo,
I was playing with the API and seems this might work for you

{{hostname-url}}/qm/service/com.ibm.rqm.integration.service.IIntegrationService/resources/{{qm-project-area-id}}/testcase?fields=feed/entry/content/testcase[title='Check that the preasure is under 100*']/*&strictFields=true&wildcard=*

Hope this helps

0 votes

Comments
Sorry. It does not help.
Please note that the % is part of the title, i do not intent do use it as a wildcard, or regex.
so i have a this two test cases:
"Check that the preasure is under 100%"
"Check that the preasure is under 100Y"

Your query will return them both, and i just whant the first one.

Sorry. It does not help.
Please note that the % is part of the title, i do not intent do use it as a wildcard, or regex.
so i have a this two test cases:
"Check that the preasure is under 100%"
"Check that the preasure is under 100Y"

Your query will return them both, and i just whant the first one.

I just tried this also:

?fields=feed/entry/content/testcase[title='Check that the preasure is under 100#%']/*&strictFields=true&wildcard=*

And return all the TestCases on the platform (not filtering by title at all).

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

Question asked: Aug 07 '20, 7:56 a.m.

Question was seen: 1,746 times

Last updated: Aug 10 '20, 5:56 a.m.

Confirmation Cancel Confirm