cancel
Showing results for 
Search instead for 
Did you mean: 

SoapUI Pro (Automate JSon payload)

SOLVED
Occasional Contributor

SoapUI Pro (Automate JSon payload)

Hi Guys,

 

I am new on SoapUI pro, here is the scenario.

 

I have four methods namely (create, update, delete, and get) for the event service, so from my update json I need to pass the eventCode which is generated from the create Method.

 

I am able to connect to the DB and I am also aware of the datasource and JDBC Request.

 

Can you please suggest a way or a link on how I can achieve this.

 

Thanks in advance,

KB Tokzan

1 ACCEPTED SOLUTION

Accepted Solutions
Occasional Contributor

Re: SoapUI Pro (Automate JSon payload)

Hi @Olga_T,

 

Yes it did .. I managed to solve my problem by using the property transfer ..

 

Thanks,

KB Tokzan

 

8 REPLIES 8
Community Hero

Re: SoapUI Pro (Automate JSon payload)

Hi,

 

Can you please share a sample response from the jdbc request?



If my answer helped please click on the 'Accept as Solution' button.
Occasional Contributor

Re: SoapUI Pro (Automate JSon payload)

Hi Lucian,

 

Thanks for the reply, please see the screen for from my jdbc response,

 

To update the very same results I need to pass the event code in my json (below)

 

{
"unitOfMeasureDescription": "RedesignUpdate",
"unitOfMeasureBusinessDescription": "RedesignUpdate",
"unitOfMeasureCode": "UOM-Rede",
"unitOfMeasureUnit": "cm",
"dataType": {
"dataTypeCode": "DECIMAL"
},
"effectiveFromDate": "2018-09-03",
"effectiveToDate": "2999-12-31"
}

 

I can update any parameter aslong as I am passing the correct/existing code.

 

As I mentioned I need to find a way that I can be able to read the code from the DB and pass it to my json without doing it manually, bacause we have to intergrate this with jenkins

 

Thanks,

KB Tokzan 

 

 

Occasional Contributor

Re: SoapUI Pro (Automate JSon payload)

Sorry forgot to attached the picture

Community Hero

Re: SoapUI Pro (Automate JSon payload)

I am sorry. I don't get what that event code is. Can you help me out here?



If my answer helped please click on the 'Accept as Solution' button.
Occasional Contributor

Re: SoapUI Pro (Automate JSon payload)

I am referring to "unitOfMeasureCode" by eventCode .. the code is is also stored on the DB if you can refer to my screenshot attachment
Community Hero

Re: SoapUI Pro (Automate JSon payload)

Ok, I am sorry but I still don't know exactly what you are trying to extract. Smiley Happy Nevertheless there is a Property Trasnfer step in SoapUI. So you could:

 

1. Create a TestCase property (see more about properties here);

2. Add a Property Transfer step 

2018-09-06_15h52_59.png

3. Reference the property wherever you need. (info about referencing properties are also in the link I provided)



If my answer helped please click on the 'Accept as Solution' button.
Moderator

Re: SoapUI Pro (Automate JSon payload)

Hi all,

 

@Lucian, thanks for trying to figure it out Smiley Very Happy

@KBTokzan, was the assumption above correct? Do the steps help you?

 

Olga Terentieva,
SmartBear Assistant Community Manager

Occasional Contributor

Re: SoapUI Pro (Automate JSon payload)

Hi @Olga_T,

 

Yes it did .. I managed to solve my problem by using the property transfer ..

 

Thanks,

KB Tokzan

 

New Here?
Join us and watch the welcome video:
Watch the new Interview
Top Kudoed Authors