Property Transfer Test Step adding extra bracket in the value
SOLVED- Bookmark
- Subscribe
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Property Transfer Test Step adding extra bracket in the value
Hi,
I'm new to SOAPUI and am currently using the OpenSource version 5.3.0. I have a Property Transfer Test step that retrieves an attribute in an element from the previous step. This Property Transfer step works; however, it's putting brackets around the value. I think this may be a result of the JSON response being an array. It is causing a problem because I am using this value in the next step for a GET request and it's placing the brackets in the GET request, causing a 404.
Is there a way to remove the brackets so that when I run the Property Transfer Step I just get "[PatientID]" instead of
"[[PatientId]]"? I've attached a screenshot of the value for clarification.
Any suggestions much appreciated!
Thanks,
Nhan
Solved! Go to Solution.
- Bookmark
- Subscribe
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
To get the first item use the expression $.ItemList[0].Id
The response was an array because [:1] notation will include all items from index 0 (inclusive) until index 1 (exclusive)
- Bookmark
- Subscribe
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
That was the issue. I'm not sure why I didn't even notice that to begin with. It's working now. Thank you!
- Bookmark
- Subscribe
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
