<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>topic Re: Retrieving XML Custom Data in Talend Studio</title>
    <link>https://community.qlik.com/t5/Talend-Studio/Retrieving-XML-Custom-Data/m-p/2296388#M69052</link>
    <description>&lt;P&gt;Can you run it the job and take a screen shot of the job just afterwards. Also, can you show me the whole xPath config for the tExtractXMLField component?&amp;nbsp;&lt;/P&gt;</description>
    <pubDate>Wed, 03 Jan 2018 14:10:18 GMT</pubDate>
    <dc:creator>Anonymous</dc:creator>
    <dc:date>2018-01-03T14:10:18Z</dc:date>
    <item>
      <title>Retrieving XML Custom Data</title>
      <link>https://community.qlik.com/t5/Talend-Studio/Retrieving-XML-Custom-Data/m-p/2296385#M69049</link>
      <description>&lt;P&gt;Hi&amp;nbsp; All,&lt;/P&gt;
&lt;P&gt;I am facing problem in retrieving certain fields like &lt;SPAN&gt;&lt;STRONG&gt;Location,Status,Source&lt;/STRONG&gt;&amp;nbsp;&lt;/SPAN&gt;from below XML.&amp;nbsp; i tried with &lt;STRONG&gt;tFileInputXML&lt;/STRONG&gt;, but its fetching all attributes id including unnecessary&amp;nbsp;&lt;SPAN&gt;&lt;STRONG&gt;guest,Tax&lt;/STRONG&gt; data. As&amp;nbsp; Can some Please Explain how can i Extract &lt;STRONG&gt;specified&lt;/STRONG&gt;&amp;nbsp;attributes(&lt;STRONG&gt;order-no,Location,Status,Source)&lt;/STRONG&gt; from XML file.&lt;/SPAN&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&lt;STRONG&gt;Sample Source File:&lt;/STRONG&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;lt;orders&amp;gt;&lt;BR /&gt;&amp;lt;order order-no="20001"&amp;gt;&lt;BR /&gt;&amp;lt;manuals&amp;gt;&lt;BR /&gt;&amp;lt;manuals state-id="Location"&amp;gt;Sydney&amp;lt;/manuals&amp;gt;&lt;BR /&gt;&amp;lt;manuals state-id="Status"&amp;gt;Success&amp;lt;/manuals&amp;gt;&lt;BR /&gt;&amp;lt;manuals state-id="guest"&amp;gt;false&amp;lt;/manuals&amp;gt;&lt;BR /&gt;&amp;lt;manuals state-id="Tax"&amp;gt;true&amp;lt;/manuals&amp;gt;&lt;BR /&gt;&amp;lt;manuals state-id="Source"&amp;gt;Web&amp;lt;/manuals&amp;gt;&lt;BR /&gt;&amp;lt;/manualss&amp;gt;&lt;BR /&gt;&amp;lt;/order&amp;gt;&lt;BR /&gt;&amp;lt;order order-no="20002"&amp;gt;&lt;BR /&gt;&amp;lt;manuals&amp;gt;&lt;BR /&gt;&amp;lt;manuals state-id="Location"&amp;gt;Mexico&amp;lt;/manuals&amp;gt;&lt;BR /&gt;&amp;lt;manuals state-id="Status"&amp;gt;Success&amp;lt;/manuals&amp;gt;&lt;BR /&gt;&amp;lt;manuals state-id="guest"&amp;gt;false&amp;lt;/manuals&amp;gt;&lt;BR /&gt;&amp;lt;manuals state-id="Source"&amp;gt;Mobile&amp;lt;/manuals&amp;gt;&lt;BR /&gt;&amp;lt;/manualss&amp;gt;&lt;BR /&gt;&amp;lt;/order&amp;gt;&lt;BR /&gt;&amp;lt;/orders&amp;gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Thanks in Advance.&lt;/P&gt;</description>
      <pubDate>Wed, 03 Jan 2018 12:06:04 GMT</pubDate>
      <guid>https://community.qlik.com/t5/Talend-Studio/Retrieving-XML-Custom-Data/m-p/2296385#M69049</guid>
      <dc:creator>kmrprvn</dc:creator>
      <dc:date>2018-01-03T12:06:04Z</dc:date>
    </item>
    <item>
      <title>Re: Retrieving XML Custom Data</title>
      <link>https://community.qlik.com/t5/Talend-Studio/Retrieving-XML-Custom-Data/m-p/2296386#M69050</link>
      <description>&lt;P&gt;Unfortunately your XML is not formatted correctly, but I am assuming that is just a copying error. Your custom-attributes elements are not closed properly (should be "&amp;lt;/custom-attributes&amp;gt;").&lt;/P&gt; 
&lt;P&gt;&amp;nbsp;&lt;/P&gt; 
&lt;P&gt;To solve this you will need to loop in the tFileUnputXML like this.....&lt;/P&gt; 
&lt;PRE&gt;"/orders/order"&lt;/PRE&gt; 
&lt;P&gt;....and create one column called "order" with an xpath expression like this....&lt;/P&gt; 
&lt;PRE&gt;"."&lt;/PRE&gt; 
&lt;P&gt;Then add a tExtractXMLField component and extract your attributes here. Your loop should be ....&lt;/P&gt; 
&lt;PRE&gt;"/"&lt;/PRE&gt; 
&lt;P&gt;....and your column xpaths will need to look like this.....&lt;/P&gt; 
&lt;PRE&gt;"//custom-attribute[@attribute-id='Location']"&lt;/PRE&gt; 
&lt;P&gt;Obviously change the attribute-id value according to what you want to extract.&lt;/P&gt; 
&lt;P&gt;&amp;nbsp;&lt;/P&gt; 
&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Wed, 03 Jan 2018 13:08:30 GMT</pubDate>
      <guid>https://community.qlik.com/t5/Talend-Studio/Retrieving-XML-Custom-Data/m-p/2296386#M69050</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2018-01-03T13:08:30Z</dc:date>
    </item>
    <item>
      <title>Re: Retrieving XML Custom Data</title>
      <link>https://community.qlik.com/t5/Talend-Studio/Retrieving-XML-Custom-Data/m-p/2296387#M69051</link>
      <description>&lt;BLOCKQUOTE&gt; 
 &lt;HR /&gt; 
 &lt;A href="https://community.qlik.com/s/profile/005390000069RuGAAU"&gt;@rhall&lt;/A&gt; wrote: 
 &lt;BR /&gt; 
 &lt;P&gt;Unfortunately your XML is not formatted correctly, but I am assuming that is just a copying error. Your custom-attributes elements are not closed properly (should be "&amp;lt;/custom-attributes&amp;gt;").&lt;/P&gt; 
 &lt;P&gt;&amp;nbsp;&lt;/P&gt; 
 &lt;P&gt;To solve this you will need to loop in the tFileUnputXML like this.....&lt;/P&gt; 
 &lt;PRE&gt;"/orders/order"&lt;/PRE&gt; 
 &lt;P&gt;....and create one column called "order" with an xpath expression like this....&lt;/P&gt; 
 &lt;PRE&gt;"."&lt;/PRE&gt; 
 &lt;P&gt;Then add a tExtractXMLField component and extract your attributes here. Your loop should be ....&lt;/P&gt; 
 &lt;PRE&gt;"/"&lt;/PRE&gt; 
 &lt;P&gt;....and your column xpaths will need to look like this.....&lt;/P&gt; 
 &lt;PRE&gt;"//custom-attribute[@attribute-id='Location']"&lt;/PRE&gt; 
 &lt;P&gt;Obviously change the attribute-id value according to what you want to extract.&lt;/P&gt; 
 &lt;P&gt;&amp;nbsp;&lt;/P&gt; 
 &lt;P&gt;&amp;nbsp;&lt;/P&gt; 
 &lt;HR /&gt; 
&lt;/BLOCKQUOTE&gt; 
&lt;P&gt;Hey Thanks for quick reply. i have corrected end tag.&lt;/P&gt; 
&lt;P&gt;&amp;nbsp;&lt;/P&gt; 
&lt;P&gt;I tried in the same way as you explained, but its returning null value.&lt;/P&gt; 
&lt;P&gt;&amp;nbsp;&lt;/P&gt; 
&lt;P&gt;&lt;SPAN class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="inputxml.JPG" style="width: 620px;"&gt;&lt;span class="lia-inline-image-display-wrapper" image-alt="0683p000009LsVJ.jpg"&gt;&lt;img src="https://community.qlik.com/t5/image/serverpage/image-id/146042iE1A1C16CD59C14FC/image-size/large?v=v2&amp;amp;px=999" role="button" title="0683p000009LsVJ.jpg" alt="0683p000009LsVJ.jpg" /&gt;&lt;/span&gt;&lt;/SPAN&gt;&lt;SPAN class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="xmlfield.JPG" style="width: 597px;"&gt;&lt;span class="lia-inline-image-display-wrapper" image-alt="0683p000009LsL7.jpg"&gt;&lt;img src="https://community.qlik.com/t5/image/serverpage/image-id/153830i9BAC6E054FD626BC/image-size/large?v=v2&amp;amp;px=999" role="button" title="0683p000009LsL7.jpg" alt="0683p000009LsL7.jpg" /&gt;&lt;/span&gt;&lt;/SPAN&gt;&lt;/P&gt;</description>
      <pubDate>Wed, 03 Jan 2018 13:58:03 GMT</pubDate>
      <guid>https://community.qlik.com/t5/Talend-Studio/Retrieving-XML-Custom-Data/m-p/2296387#M69051</guid>
      <dc:creator>kmrprvn</dc:creator>
      <dc:date>2018-01-03T13:58:03Z</dc:date>
    </item>
    <item>
      <title>Re: Retrieving XML Custom Data</title>
      <link>https://community.qlik.com/t5/Talend-Studio/Retrieving-XML-Custom-Data/m-p/2296388#M69052</link>
      <description>&lt;P&gt;Can you run it the job and take a screen shot of the job just afterwards. Also, can you show me the whole xPath config for the tExtractXMLField component?&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Wed, 03 Jan 2018 14:10:18 GMT</pubDate>
      <guid>https://community.qlik.com/t5/Talend-Studio/Retrieving-XML-Custom-Data/m-p/2296388#M69052</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2018-01-03T14:10:18Z</dc:date>
    </item>
    <item>
      <title>Re: Retrieving XML Custom Data</title>
      <link>https://community.qlik.com/t5/Talend-Studio/Retrieving-XML-Custom-Data/m-p/2296389#M69053</link>
      <description>&lt;P&gt;Thanks alot rhall.&lt;/P&gt;
&lt;P&gt;There is a spell mistake. its working as expected.&lt;/P&gt;</description>
      <pubDate>Wed, 03 Jan 2018 14:32:28 GMT</pubDate>
      <guid>https://community.qlik.com/t5/Talend-Studio/Retrieving-XML-Custom-Data/m-p/2296389#M69053</guid>
      <dc:creator>kmrprvn</dc:creator>
      <dc:date>2018-01-03T14:32:28Z</dc:date>
    </item>
  </channel>
</rss>

