XLS to XML transformation

Hi,

How do I create a graph to read an XLS file and write it to an XML file? Would it just be XLSDataReader → Partition → XMLWriter?

I have successfully read in the XLS file (i think) with 4 columns, say: $Col1:=#A;$Col2:=#B;$Col3:=#C;$Col4:=#D; How would I now write this to an XML?

How do I format the mapping of the XML if I wanted something like:


<SomeXML value="Col1">
    <Element constant="some string here" />
    <Property>
       <Value name="Name">Col2</Value>
       <Value name="Name2">Col4</Value>
    </Property>
    <AnotherElement name="Col3" />
</SomeXML>

Hello,
if you don’t need to join data from different ports to your output file you can use StructureWriter. The graph is very easy: XLSDataReader → StructureWriter and you don’t need any complicated mapping:

<Node fileURL="${DATAOUT_DIR}/xml.out" id="STRUCTURE_WRITER0" mask="&lt;SomeXML value=&quot;$Col1&quot;&gt;&#10;    &lt;Element constant=&quot;some string here&quot; /&gt;&#10;    &lt;Property&gt;&#10;       &lt;Value name=&quot;Name&quot;&gt;$Col2&lt;/Value&gt;&#10;       &lt;Value name=&quot;Name2&quot;&gt;$Col4&lt;/Value&gt;&#10;    &lt;/Property&gt;&#10;    &lt;AnotherElement name=&quot;$Col3&quot; /&gt;&#10;&lt;/SomeXML&gt;&#10;" type="STRUCTURE_WRITER"/>

Thank you! This worked great