XML Data Bank to Write File

LegacyForumLegacyForum Posts: 1,669 ✭✭
edited December 2016 in SOAtest
XML Data Bank to Write File
Is there a way to use the write file tool to create a file based on a parameter that is saved by the XML Databank?

For example, I have a response which I've saved one of the values in the XPath and the data source column name is called "getPreparedDataReturn". Can I create a file with this response and save it to my local hard drive? If so, can the name of the file be identified by a parameter that I have passed into the request?

Thanks in advance.
Tagged:

Comments

  • LegacyForumLegacyForum Posts: 1,669 ✭✭
    My understanding of what you're trying to do is to save the value of an element from the response into a file and make the file name the same as an input in the request. Is this correct? If so, the first part is possible by using a XML Transformer to select an element in the response and a Write File Tool to write the value into a file.

    For the second part, there is no way to automatically use an input value from the request for the file name. If you want to generate a file name, then there is a list of wildcards that may be helpful. To see this list, click on the Write File Tool and click on the Help button next to Target name. For instance, %n would insert the test name into the file name.

    I've attached an example test suite. Let me know if you have more questions.
Sign In or Register to comment.