ContributionsMost RecentMost LikesSolutionsRe: Property transfer return empty array in JSON response That is the perfect solution. After I changed it to single quotes and added[0] at the end, I got the first phone element. Thank you very much for the suggestion! Re: jsonpathRetrieve array element in an array from JSON response That was my problem. I'm now getting the first phone number. I will eventually need to create a step to filter by phone type so this will be very helpful. Thank you! jsonpathRetrieve array element in an array from JSON response Hi All, I'm trying to retrieve an array element within an array (sample response attached) from a test step in a test case. Within this response, I want to retrieve an array of Telecoms values where the SystemCode ==phone and then get the first element from this array to use in another step. I tried doing this with a property transfer step, but the problem is that when I retrieve the array using this JSONpath as the source, it returns an empty array even though I it should return an array of 25 elements. $..Telecoms[?(@.SystemCode=="phone")].ValueString So, I'm trying to do this with Groovy script. I'm not familiar with Groovy, so I'm cobbling this together based on what I've been reading. I know the syntax isn't correct, but I'm hoping I can get some help to get what I need with this bit of pseudocode: import groovy.json.JsonSlurper //retrieve response from the 'All Matches' test step def response = context.expand( '${TestStepName#AllMatches}' ).toString() def slurper = new JsonSlurper() def json = slurper.parseText(response) //get an array of values where the Telecoms.SystemCode = 'phone' def phoneArray = log.info(json.Itemlist.Telecoms[?(@.SystemCode=="phone")].ValueString) //get the first element from phoneArray def phoneElement = jsonParse[0] SolvedProperty transfer return empty array in JSON response Hello, I have a test step that returns a JSON response (sample response attached). In a subsequent step, I do a property transfer in which a take the first element in the response and, in the Telecoms node, I want to grab the first element in the Telecoms array where the 'SystemCode = 'email' . I know this is not correct because when I use a JSON online evaluator, it will return ALL elements where SystemCode ='email' --all 25--, not just the first one it finds. $..Telecoms[?(@.SystemCode=="email")].ValueString Moreover, when I run the testSuite and I look at what is returned in the Email property transfer, it returns and empty array (screenshots attached). My questions are: 1. What is the correct format for the Source in the property transfer so that I only get the first element in the JSON Response, and within the Telecoms node of that element, I get the first element where 'SystemCode = 'email' 2. If I can't do this in a Property Transfer step, what is the best way to accomplish this? 2. Am I seeing an empty array in the results email property transfer because there a limitation i in terms of the number of elements it can return in an array, and if the response returns more than it can handle, it returns an empty response? SolvedRe: testrunner.bat: syntax of command line incorrect Thank you. The issue was the first one you suggested in which the command had to be in one single line. My command was, in fact, in two lines. After I removed the extra return, it ran as one single line and completed. Re: testrunner.bat: syntax of command line incorrect Thanks for the suggestion. I compared it to the SOAP project that ran successfully and that parameter is set that way. It turns out my issue was due to the command line not being on one line. After I removed the extra line, the test ran. testrunner.bat: syntax of command line incorrect I am trying to run a SOAPUI opensource test suite via TeamCity. In TeamCity, there is a step that calls testrunner.bat and constructs the command line based on the parameters/parameter values I add. The command line constructed is attached, along with the subsequent error: [Step 1/1] The syntax of the command is incorrect. [Step 1/1] Process exited with code 255 I have compared it to another SOAP project that runs successfully in TeamCity, and save for a few additional parameters in the other project, they look similar. In addition, I can run my test suite in SOAPUI successfully. Is there a way to troubleshoot where in my command line it is failing? Are there any restrictions that I'm not aware of using OpenSource to do this? SolvedRe: Property Transfer Test Step adding extra bracket in the value That was the issue. I'm not sure why I didn't even notice that to begin with. It's working now. Thank you! 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