<?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: Split string and find index in Talend Studio</title>
    <link>https://community.qlik.com/t5/Talend-Studio/Split-string-and-find-index/m-p/2256522#M38878</link>
    <description>thank you &lt;span class="lia-unicode-emoji" title=":slightly_smiling_face:"&gt;🙂&lt;/span&gt;</description>
    <pubDate>Tue, 12 Feb 2019 07:35:43 GMT</pubDate>
    <dc:creator>Gabri11</dc:creator>
    <dc:date>2019-02-12T07:35:43Z</dc:date>
    <item>
      <title>Split string and find index</title>
      <link>https://community.qlik.com/t5/Talend-Studio/Split-string-and-find-index/m-p/2256519#M38875</link>
      <description>&lt;P&gt;&lt;SPAN class="tlid-translation translation"&gt;&lt;SPAN&gt;hi, I have two fields (field1 and field2).&lt;/SPAN&gt; &lt;SPAN&gt;field1 is of the type "800; 805; 116; 809; 804; 830; 346; 345; 890; 881; 0; 0; 0; 0; 0; 0; 0; 0; 0; 0" while field2 is of the type&lt;/SPAN&gt; &lt;SPAN&gt;"&lt;/SPAN&gt;&lt;SPAN&gt;1&lt;/SPAN&gt;&lt;SPAN&gt;; 0;&lt;/SPAN&gt; &lt;SPAN&gt;215&lt;/SPAN&gt;&lt;SPAN&gt;; 0;&lt;/SPAN&gt; &lt;SPAN&gt;0;&lt;/SPAN&gt; &lt;SPAN&gt;1;&lt;/SPAN&gt; &lt;SPAN&gt;2;&lt;/SPAN&gt; &lt;SPAN&gt;66;&lt;/SPAN&gt; &lt;SPAN&gt;5;&lt;/SPAN&gt; &lt;SPAN&gt;0; 0;&lt;/SPAN&gt; &lt;SPAN&gt;0; 0;&lt;/SPAN&gt; &lt;SPAN&gt;0; 0;&lt;/SPAN&gt; &lt;SPAN&gt;0; 0;&lt;/SPAN&gt; &lt;SPAN&gt;0; 0;&lt;/SPAN&gt; &lt;SPAN&gt;0".&lt;/SPAN&gt; &lt;SPAN class=""&gt;I would need to extract from field2 the value corresponding to the index searched in field1 (eg I look for "800" in field1 and extract "1" from field2, for example I look for "116" in field1 and extract "215" from field2).&lt;/SPAN&gt; &lt;SPAN class=""&gt;This I would need to do it within tmap.&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN class="tlid-translation translation"&gt;&lt;SPAN class=""&gt;I hope I have not made too much confusion ..... &lt;span class="lia-unicode-emoji" title=":slightly_smiling_face:"&gt;🙂&lt;/span&gt;&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;thanks a lot&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;/P&gt;</description>
      <pubDate>Mon, 11 Feb 2019 18:07:45 GMT</pubDate>
      <guid>https://community.qlik.com/t5/Talend-Studio/Split-string-and-find-index/m-p/2256519#M38875</guid>
      <dc:creator>Gabri11</dc:creator>
      <dc:date>2019-02-11T18:07:45Z</dc:date>
    </item>
    <item>
      <title>Re: Split string and find index</title>
      <link>https://community.qlik.com/t5/Talend-Studio/Split-string-and-find-index/m-p/2256520#M38876</link>
      <description>&lt;P&gt;Hi&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;you can do this thru Java code,&amp;nbsp;and if you want to do this with build components:&lt;/P&gt;
&lt;UL&gt;
 &lt;LI&gt;use tNormalize for split row into many rows&lt;/LI&gt;
 &lt;LI&gt;add row number to the flow - sequence&lt;/LI&gt;
 &lt;LI&gt;join in tMap by row number&lt;/LI&gt;
&lt;/UL&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;regards, Vlad&lt;/P&gt;</description>
      <pubDate>Mon, 11 Feb 2019 21:19:22 GMT</pubDate>
      <guid>https://community.qlik.com/t5/Talend-Studio/Split-string-and-find-index/m-p/2256520#M38876</guid>
      <dc:creator>vapukov</dc:creator>
      <dc:date>2019-02-11T21:19:22Z</dc:date>
    </item>
    <item>
      <title>Re: Split string and find index</title>
      <link>https://community.qlik.com/t5/Talend-Studio/Split-string-and-find-index/m-p/2256521#M38877</link>
      <description>in Tmap buiding expression, use below expression 
&lt;BR /&gt; 
&lt;BR /&gt;field2.split(";")[java.util.Arrays.asList(field1.split(";")).indexOf("stringtosearch")] 
&lt;BR /&gt; 
&lt;BR /&gt;e.g. 
&lt;BR /&gt;String f1 = "800;801;802;803"; 
&lt;BR /&gt;String f2 = "X;Y;Z;G"; 
&lt;BR /&gt;f2.split(";")[java.util.Arrays.asList(f1.split(";")).indexOf("801")] 
&lt;BR /&gt;this will return Y</description>
      <pubDate>Mon, 11 Feb 2019 21:25:24 GMT</pubDate>
      <guid>https://community.qlik.com/t5/Talend-Studio/Split-string-and-find-index/m-p/2256521#M38877</guid>
      <dc:creator>akumar2301</dc:creator>
      <dc:date>2019-02-11T21:25:24Z</dc:date>
    </item>
    <item>
      <title>Re: Split string and find index</title>
      <link>https://community.qlik.com/t5/Talend-Studio/Split-string-and-find-index/m-p/2256522#M38878</link>
      <description>thank you &lt;span class="lia-unicode-emoji" title=":slightly_smiling_face:"&gt;🙂&lt;/span&gt;</description>
      <pubDate>Tue, 12 Feb 2019 07:35:43 GMT</pubDate>
      <guid>https://community.qlik.com/t5/Talend-Studio/Split-string-and-find-index/m-p/2256522#M38878</guid>
      <dc:creator>Gabri11</dc:creator>
      <dc:date>2019-02-12T07:35:43Z</dc:date>
    </item>
  </channel>
</rss>

