<?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: Spliting String on space in Talend Studio</title>
    <link>https://community.qlik.com/t5/Talend-Studio/Spliting-String-on-space/m-p/2316919#M87426</link>
    <description>&lt;P&gt;Thanx, it actually solved it ^^&lt;/P&gt;</description>
    <pubDate>Mon, 22 Jan 2018 23:19:45 GMT</pubDate>
    <dc:creator>Anonymous</dc:creator>
    <dc:date>2018-01-22T23:19:45Z</dc:date>
    <item>
      <title>Spliting String on space</title>
      <link>https://community.qlik.com/t5/Talend-Studio/Spliting-String-on-space/m-p/2316917#M87424</link>
      <description>&lt;P&gt;Hi, if someone could please help me, i'm trying to split a string like this:&lt;BR /&gt;&lt;BR /&gt;&lt;/P&gt;&lt;P&gt;String s1=input_row.m_lines;&lt;BR /&gt;int pos=s1.indexOf(":");&lt;/P&gt;&lt;P&gt;context.Line=s1.substring(0,pos) ;&amp;nbsp;&lt;BR /&gt;context.Mask=s1.substring(pos+1) ;&amp;nbsp;&lt;/P&gt;&lt;P&gt;String str = s1.substring(0,pos) ;&lt;BR /&gt;String[] splited = str.split("\\s+");&lt;/P&gt;&lt;P&gt;//System.out.println(context.Line);&lt;BR /&gt;System.out.println(splited);&lt;BR /&gt;&lt;BR /&gt;and it gives me this:&lt;/P&gt;&lt;P&gt;[statistics] connecting to socket on port 3496&lt;BR /&gt;[statistics] connected&lt;BR /&gt;[Ljava.lang.String;@2669b199&lt;/P&gt;&lt;P&gt;[Ljava.lang.String;@2344fc66&lt;/P&gt;&lt;P&gt;[Ljava.lang.String;@458ad742&lt;BR /&gt;[statistics] disconnected&lt;BR /&gt;&lt;BR /&gt;The output of&amp;nbsp;&lt;SPAN&gt;System.out.println(context.Line)&lt;/SPAN&gt; without the split function is:&lt;/P&gt;&lt;P&gt;Name&lt;/P&gt;&lt;P&gt;Surname&lt;/P&gt;&lt;P&gt;Email&lt;BR /&gt;&lt;BR /&gt;i want to split all and store each in different variables, anyways to do so?&lt;/P&gt;</description>
      <pubDate>Mon, 22 Jan 2018 19:35:19 GMT</pubDate>
      <guid>https://community.qlik.com/t5/Talend-Studio/Spliting-String-on-space/m-p/2316917#M87424</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2018-01-22T19:35:19Z</dc:date>
    </item>
    <item>
      <title>Re: Spliting String on space</title>
      <link>https://community.qlik.com/t5/Talend-Studio/Spliting-String-on-space/m-p/2316918#M87425</link>
      <description>&lt;P&gt;Hi,&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;please note that you do not print out the content of your Array after split.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&amp;lt;&amp;lt; System.out.println(splited);&lt;/P&gt;
&lt;P&gt;To print out a value stored in the array you would acces it like :&amp;nbsp;&lt;SPAN&gt;System.out.println(splited[0]);&lt;/SPAN&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&lt;SPAN&gt;See also following snippet and try it out :&lt;/SPAN&gt;&lt;/P&gt;
&lt;P&gt;String s1="Hello my dear I do have something to say I hope you gonna like it";&lt;BR /&gt;&lt;BR /&gt;String[] splited = s1.split("\\s+");&lt;/P&gt;
&lt;P&gt;//System.out.println(context.Line);&lt;BR /&gt;System.out.println(splited);&lt;BR /&gt;&lt;BR /&gt;for(String w:splited){&lt;BR /&gt;System.out.println(w);&lt;BR /&gt;}&lt;/P&gt;
&lt;P&gt;The output will be :&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;[Ljava.lang.String;@7852e922&lt;BR /&gt;Hello&lt;BR /&gt;my&lt;BR /&gt;dear&lt;BR /&gt;I&lt;BR /&gt;do&lt;BR /&gt;have&lt;BR /&gt;something&lt;BR /&gt;to&lt;BR /&gt;say&lt;BR /&gt;I&lt;BR /&gt;hope&lt;BR /&gt;you&lt;BR /&gt;gonna&lt;BR /&gt;like&lt;BR /&gt;it&lt;/P&gt;
&lt;P&gt;----------------------------&lt;/P&gt;
&lt;P&gt;I hope it helps&lt;/P&gt;
&lt;P&gt;BR B_p&lt;/P&gt;</description>
      <pubDate>Mon, 22 Jan 2018 22:47:21 GMT</pubDate>
      <guid>https://community.qlik.com/t5/Talend-Studio/Spliting-String-on-space/m-p/2316918#M87425</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2018-01-22T22:47:21Z</dc:date>
    </item>
    <item>
      <title>Re: Spliting String on space</title>
      <link>https://community.qlik.com/t5/Talend-Studio/Spliting-String-on-space/m-p/2316919#M87426</link>
      <description>&lt;P&gt;Thanx, it actually solved it ^^&lt;/P&gt;</description>
      <pubDate>Mon, 22 Jan 2018 23:19:45 GMT</pubDate>
      <guid>https://community.qlik.com/t5/Talend-Studio/Spliting-String-on-space/m-p/2316919#M87426</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2018-01-22T23:19:45Z</dc:date>
    </item>
  </channel>
</rss>

