09-23-2020 03:45 PM
I’m formatting and writing an xml file, and would like to name the file based on a field value from the original file, but cannot be part of the xml. Is it possible to somehow bring a variable ($VAR) from a prior step in to the File Writer without including it in the preceeding XML?
‘response-s-’$VAR’+‘-.xml’
Solved! Go to Solution.
09-23-2020 10:57 PM
@acesario You can segregate xml format and file writer in different pipeline, then call this child pipeline using Pipeline execute and pass input param(the filename you want ) from your parent pipeline. Even if you use xsd inside xml format, you can found the xsd structure from the mapper(Map to xml) of your parent pipeline.
09-24-2020 06:48 AM
@Supratim, I found a way to resolve this. I used a GATE snap on the parent to combine the rows, and a json splitter on the child along with the parameter for the file naming.
WORKS PERFECTLY! Thank you for the continued conversation and ideas.