Extract SOAP XML attribute value from datafile to provide JDBC request with query filter value
SOLVED- Bookmark
- Subscribe
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Extract SOAP XML attribute value from datafile to provide JDBC request with query filter value
Hi,
Its been years since I used SoapUI Pro (I was never that good with it to begin with) and I'm now using ReadyAPI! v1.9.0 and I'm struggling.
I have 80 test data files (XML) which will be used to populate the body of a Soap message being posted to a web service. Within these XML files is an attribute value (RecordID) I need to source to populate the where clause of a query filter in a JDBC step. I've followed the instructions that I've found and done various google searches, however, I'm still struggling so I'm hopeful someone can help!
My hierarchy is as follows:
Datasource step (Type=File, Property = FileContent, no separator, charset=UTF-8) Soap step (body tag value = ${DataSource#FileContent}) Property Transfer step (Property=GetRecordID, Source=Datasource, Property=FileContent, PathLanguage=XPath, value=//*:RootElement/Element/@RecordID) JDBC step (select * from table where RecordID='value I need from XML datafile')
I apologise if I'm asking a stupid question or for wasting anyone's time.
I do appreciate any and all guidance anyone can provide!
Cheers!
Solved! Go to Solution.
- Bookmark
- Subscribe
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Much thanks to go to nmrao & Radford for holding my hand until I sorted the problem.
I still haven't identified why it wasn't working other than copying and pasting the datasource details into the groovyscript didn't appear to pickup the Datasource's propertyname - I had to use GetData context menu before it would recognise my '${DataSource#FileContents}' property for some reason.
Anyway - success! so thanks again!

- « Previous
-
- 1
- 2
- Next »
- « Previous
-
- 1
- 2
- Next »