<?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: manipulate phone number tMap in Talend Studio</title>
    <link>https://community.qlik.com/t5/Talend-Studio/manipulate-phone-number-tMap/m-p/2208572#M7742</link>
    <description>The phone number quality is good but the numbers are sometimes longer sometimes shorter.
&lt;BR /&gt;Can it be done with tReplace?
&lt;BR /&gt;Thank you very much.</description>
    <pubDate>Thu, 24 Feb 2011 18:46:49 GMT</pubDate>
    <dc:creator>Anonymous</dc:creator>
    <dc:date>2011-02-24T18:46:49Z</dc:date>
    <item>
      <title>manipulate phone number tMap</title>
      <link>https://community.qlik.com/t5/Talend-Studio/manipulate-phone-number-tMap/m-p/2208568#M7738</link>
      <description>Hello,
&lt;BR /&gt;how it´s possible to add the international prefix to a national phone number?
&lt;BR /&gt;I have the following number 0775188060 and want +49775188060.
&lt;BR /&gt;Greetings</description>
      <pubDate>Sat, 16 Nov 2024 13:04:29 GMT</pubDate>
      <guid>https://community.qlik.com/t5/Talend-Studio/manipulate-phone-number-tMap/m-p/2208568#M7738</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2024-11-16T13:04:29Z</dc:date>
    </item>
    <item>
      <title>Re: manipulate phone number tMap</title>
      <link>https://community.qlik.com/t5/Talend-Studio/manipulate-phone-number-tMap/m-p/2208569#M7739</link>
      <description>Hi 
&lt;BR /&gt;Is there any other records indicates what's the international prefix should be added to number? 
&lt;BR /&gt;Best regards 
&lt;BR /&gt;Shong</description>
      <pubDate>Thu, 24 Feb 2011 13:49:45 GMT</pubDate>
      <guid>https://community.qlik.com/t5/Talend-Studio/manipulate-phone-number-tMap/m-p/2208569#M7739</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2011-02-24T13:49:45Z</dc:date>
    </item>
    <item>
      <title>Re: manipulate phone number tMap</title>
      <link>https://community.qlik.com/t5/Talend-Studio/manipulate-phone-number-tMap/m-p/2208570#M7740</link>
      <description>Hello,
&lt;BR /&gt;I only import one country so all prefixes are same.
&lt;BR /&gt;It´s not a mixed import, I import country by country so I only need to know how to replace the first zero with +49
&lt;BR /&gt;I don´t have a field with the country prefix inside so I can not combinate two fields.
&lt;BR /&gt;Greetings</description>
      <pubDate>Thu, 24 Feb 2011 16:26:06 GMT</pubDate>
      <guid>https://community.qlik.com/t5/Talend-Studio/manipulate-phone-number-tMap/m-p/2208570#M7740</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2011-02-24T16:26:06Z</dc:date>
    </item>
    <item>
      <title>Re: manipulate phone number tMap</title>
      <link>https://community.qlik.com/t5/Talend-Studio/manipulate-phone-number-tMap/m-p/2208571#M7741</link>
      <description>Hi Loki555, 
&lt;BR /&gt;If there's good data quality on your source phone number, you can use a tMap to transform it using the following expression, given it is in String format : 
&lt;BR /&gt;"+49"+StringHandling.RIGHT(row1.phoneNumber,9) 
&lt;BR /&gt;Regards,</description>
      <pubDate>Thu, 24 Feb 2011 16:47:20 GMT</pubDate>
      <guid>https://community.qlik.com/t5/Talend-Studio/manipulate-phone-number-tMap/m-p/2208571#M7741</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2011-02-24T16:47:20Z</dc:date>
    </item>
    <item>
      <title>Re: manipulate phone number tMap</title>
      <link>https://community.qlik.com/t5/Talend-Studio/manipulate-phone-number-tMap/m-p/2208572#M7742</link>
      <description>The phone number quality is good but the numbers are sometimes longer sometimes shorter.
&lt;BR /&gt;Can it be done with tReplace?
&lt;BR /&gt;Thank you very much.</description>
      <pubDate>Thu, 24 Feb 2011 18:46:49 GMT</pubDate>
      <guid>https://community.qlik.com/t5/Talend-Studio/manipulate-phone-number-tMap/m-p/2208572#M7742</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2011-02-24T18:46:49Z</dc:date>
    </item>
    <item>
      <title>Re: manipulate phone number tMap</title>
      <link>https://community.qlik.com/t5/Talend-Studio/manipulate-phone-number-tMap/m-p/2208573#M7743</link>
      <description>You're right ! You can do it with a tReplace, but you have to make sure that the phone numbers begin with a zero (by filtering with a tMap before), otherwise the prefix won't be concatenated. 
&lt;BR /&gt;See enclosed screenshot, with a simple regex that replace the 0 if it is the first character of the string. 
&lt;BR /&gt;Another way to do that, a little bit more obfuscated, but quicker ! 
&lt;BR /&gt;"+49"+source.phoneNumber.substring(1,source.phoneNumber.length()) 
&lt;BR /&gt;It replaces the first character of the string with "+49" in all cases, but without making sure it was a 0. 
&lt;BR /&gt;The key is to make sure you have good data quality on your source data !</description>
      <pubDate>Fri, 25 Feb 2011 17:33:59 GMT</pubDate>
      <guid>https://community.qlik.com/t5/Talend-Studio/manipulate-phone-number-tMap/m-p/2208573#M7743</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2011-02-25T17:33:59Z</dc:date>
    </item>
    <item>
      <title>Re: manipulate phone number tMap</title>
      <link>https://community.qlik.com/t5/Talend-Studio/manipulate-phone-number-tMap/m-p/2208574#M7744</link>
      <description>It worked a while but now I get an error: 
&lt;BR /&gt; connecting to socket on port 3733 
&lt;BR /&gt; connected 
&lt;BR /&gt;Exception in component tMap_1 
&lt;BR /&gt;java.lang.StringIndexOutOfBoundsException: String index out of range: -1 
&lt;BR /&gt; at java.lang.String.substring(Unknown Source) 
&lt;BR /&gt;I don´t understand why because I don´t change anythig. Unknown Source ... I deleted the expression 
&lt;BR /&gt;"+49"+Kundenadressen.AQAYNA.substring(1,Kundenadressen.AQAYNA.length()) 
&lt;BR /&gt;and rewrite it, the source field is linked emediatly but when I restart I get the same error. 
&lt;BR /&gt;When I delete the expression I get no error. 
&lt;BR /&gt;Greetings 
&lt;BR /&gt;Peter</description>
      <pubDate>Tue, 01 Mar 2011 07:51:20 GMT</pubDate>
      <guid>https://community.qlik.com/t5/Talend-Studio/manipulate-phone-number-tMap/m-p/2208574#M7744</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2011-03-01T07:51:20Z</dc:date>
    </item>
    <item>
      <title>Re: manipulate phone number tMap</title>
      <link>https://community.qlik.com/t5/Talend-Studio/manipulate-phone-number-tMap/m-p/2208575#M7745</link>
      <description>Beware of null/empty strings ! 
&lt;BR /&gt;For this expression I gave you, I assume that the column containing the phone number is properly filled with 
&lt;I&gt;consistent&lt;/I&gt; data (I mean correct length, no null values, no empty strings, etc...). 
&lt;BR /&gt;If not, filter it upstream before applying this expression / correctly manage inconsistent data, otherwise you'll get NullPointerExceptions, or ArrayIndexOutOfBoundsExceptions when trying to substring.</description>
      <pubDate>Tue, 01 Mar 2011 10:07:16 GMT</pubDate>
      <guid>https://community.qlik.com/t5/Talend-Studio/manipulate-phone-number-tMap/m-p/2208575#M7745</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2011-03-01T10:07:16Z</dc:date>
    </item>
  </channel>
</rss>

