<?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: replace question in QlikView</title>
    <link>https://community.qlik.com/t5/QlikView/replace-question/m-p/318282#M117320</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;look into mapsubstring(), this might do what you want&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;edit from HELP:&lt;/P&gt;&lt;H4&gt;&lt;A name="kanchor829"&gt;&lt;/A&gt;&lt;A name="mapsubstring"&gt;&lt;/A&gt;mapsubstring( &lt;SPAN style="font-style: italic;"&gt;'mapname', expr&lt;/SPAN&gt; )&lt;/H4&gt;&lt;P&gt;This function can be used for mapping parts of any expression on a previously loaded mapping table. The mapping is case sensitive and non-recursive. The substrings are mapped from the left to the right. &lt;SPAN style="font-style: italic;"&gt;Mapname&lt;/SPAN&gt; is the name of a mapping table previously read by a &lt;SPAN class="Bold"&gt;&lt;A _jive_internal="true" href="https://community.qlik.com/Mapping.htm"&gt;mapping&lt;/A&gt; load&lt;/SPAN&gt; or a &lt;SPAN class="Bold"&gt;mapping select&lt;/SPAN&gt; statement. The name must be enclosed by single straight quotation marks. &lt;SPAN style="font-style: italic;"&gt;Expr&lt;/SPAN&gt; is the expression whose result should be mapped by substrings.&lt;/P&gt;&lt;H2&gt;Examples:&lt;/H2&gt;&lt;P&gt;&lt;SPAN style="color: #000000;"&gt;// Assume the following mapping table:&lt;/SPAN&gt; &lt;/P&gt;&lt;P&gt;&lt;SPAN style="color: #000000;"&gt;map1:&lt;/SPAN&gt; &lt;/P&gt;&lt;P&gt;&lt;SPAN style="color: #000000;"&gt;mapping load * inline [&lt;/SPAN&gt; &lt;/P&gt;&lt;P&gt;&lt;SPAN style="color: #000000;"&gt;x, y&lt;/SPAN&gt; &lt;/P&gt;&lt;P&gt;&lt;SPAN style="color: #000000;"&gt;1, &amp;lt;one&amp;gt;&lt;/SPAN&gt; &lt;/P&gt;&lt;P&gt;&lt;SPAN style="color: #000000;"&gt;aa, XYZ&lt;/SPAN&gt; &lt;/P&gt;&lt;P&gt;&lt;SPAN style="color: #000000;"&gt;x, b ] ;&lt;/SPAN&gt; &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;TABLE cellspacing="0" style="margin-top: 14pt; width: 450px; margin-left: 80px;" width="450"&gt;&lt;TBODY&gt;&lt;TR&gt;&lt;TD style="width: 51%; padding: 7px;" valign="top" width="51%"&gt;&lt;P&gt;&lt;SPAN class="Bold"&gt;MapSubstring ( 'map1', 'A123' )&lt;/SPAN&gt; &lt;/P&gt;&lt;/TD&gt;&lt;TD style="width: 23%; padding: 7px;" valign="top" width="23%"&gt;&lt;P&gt;returns&lt;/P&gt;&lt;/TD&gt;&lt;TD style="width: 26%; padding: 7px;" valign="top" width="26%"&gt;&lt;P&gt;&lt;SPAN class="Bold"&gt;' A&amp;lt;one&amp;gt;23'&lt;/SPAN&gt; &lt;/P&gt;&lt;/TD&gt;&lt;/TR&gt;&lt;TR&gt;&lt;TD style="width: 51%; padding: 7px;" valign="top" width="51%"&gt;&lt;P&gt;&lt;SPAN class="Bold"&gt;MapSubstring ( 'map1', 'baaar' )&lt;/SPAN&gt; &lt;/P&gt;&lt;/TD&gt;&lt;TD style="width: 23%; padding: 7px;" valign="top" width="23%"&gt;&lt;P&gt;returns&lt;/P&gt;&lt;/TD&gt;&lt;TD style="width: 26%; padding: 7px;" valign="top" width="26%"&gt;&lt;P&gt;&lt;SPAN class="Bold"&gt;' bXYZar'&lt;/SPAN&gt; &lt;/P&gt;&lt;/TD&gt;&lt;/TR&gt;&lt;TR&gt;&lt;TD style="width: 51%; padding: 7px;" valign="top" width="51%"&gt;&lt;P&gt;&lt;SPAN class="Bold"&gt;MapSubstring ( 'map1', 'xaa1' )&lt;/SPAN&gt; &lt;/P&gt;&lt;/TD&gt;&lt;TD style="width: 23%; padding: 7px;" valign="top" width="23%"&gt;&lt;P&gt;returns&lt;/P&gt;&lt;/TD&gt;&lt;TD style="width: 26%; padding: 7px;" valign="top" width="26%"&gt;&lt;P&gt;&lt;SPAN class="Bold"&gt;' bXYZ&amp;lt;one&amp;gt;'&lt;/SPAN&gt; &lt;/P&gt;&lt;/TD&gt;&lt;/TR&gt;&lt;/TBODY&gt;&lt;/TABLE&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Mon, 14 Nov 2011 17:20:30 GMT</pubDate>
    <dc:creator>swuehl</dc:creator>
    <dc:date>2011-11-14T17:20:30Z</dc:date>
    <item>
      <title>replace question</title>
      <link>https://community.qlik.com/t5/QlikView/replace-question/m-p/318279#M117317</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;REPLACE(text,value1,value2)&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;i want to use the REPLACE on a certain field, but i have a list of values that should be replace. &lt;/P&gt;&lt;P&gt;Can i use APPLYMAP for this, combines with REPLACE? someone has an example?&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 14 Nov 2011 16:51:31 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/replace-question/m-p/318279#M117317</guid>
      <dc:creator>amien</dc:creator>
      <dc:date>2011-11-14T16:51:31Z</dc:date>
    </item>
    <item>
      <title>replace question</title>
      <link>https://community.qlik.com/t5/QlikView/replace-question/m-p/318280#M117318</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;You could apply Replace multiple times, one time for each value you need to replace.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Like &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;LOAD &lt;/P&gt;&lt;P&gt;...&lt;/P&gt;&lt;P&gt;Replace(Replace(Replace('ABC','A','First'),'B','Second'),'C','Third') as ReplacedString,&lt;/P&gt;&lt;P&gt;...&lt;/P&gt;&lt;P&gt;FROM ...;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 14 Nov 2011 17:15:21 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/replace-question/m-p/318280#M117318</guid>
      <dc:creator>swuehl</dc:creator>
      <dc:date>2011-11-14T17:15:21Z</dc:date>
    </item>
    <item>
      <title>replace question</title>
      <link>https://community.qlik.com/t5/QlikView/replace-question/m-p/318281#M117319</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Thanks for your reply&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Yes, i know .. but i have a lot of replacements to do. APPLYMAP would be much nicer and easier to maintain.&lt;/P&gt;&lt;P&gt;I'm really looking for a INLINE option&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 14 Nov 2011 17:17:41 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/replace-question/m-p/318281#M117319</guid>
      <dc:creator>amien</dc:creator>
      <dc:date>2011-11-14T17:17:41Z</dc:date>
    </item>
    <item>
      <title>Re: replace question</title>
      <link>https://community.qlik.com/t5/QlikView/replace-question/m-p/318282#M117320</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;look into mapsubstring(), this might do what you want&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;edit from HELP:&lt;/P&gt;&lt;H4&gt;&lt;A name="kanchor829"&gt;&lt;/A&gt;&lt;A name="mapsubstring"&gt;&lt;/A&gt;mapsubstring( &lt;SPAN style="font-style: italic;"&gt;'mapname', expr&lt;/SPAN&gt; )&lt;/H4&gt;&lt;P&gt;This function can be used for mapping parts of any expression on a previously loaded mapping table. The mapping is case sensitive and non-recursive. The substrings are mapped from the left to the right. &lt;SPAN style="font-style: italic;"&gt;Mapname&lt;/SPAN&gt; is the name of a mapping table previously read by a &lt;SPAN class="Bold"&gt;&lt;A _jive_internal="true" href="https://community.qlik.com/Mapping.htm"&gt;mapping&lt;/A&gt; load&lt;/SPAN&gt; or a &lt;SPAN class="Bold"&gt;mapping select&lt;/SPAN&gt; statement. The name must be enclosed by single straight quotation marks. &lt;SPAN style="font-style: italic;"&gt;Expr&lt;/SPAN&gt; is the expression whose result should be mapped by substrings.&lt;/P&gt;&lt;H2&gt;Examples:&lt;/H2&gt;&lt;P&gt;&lt;SPAN style="color: #000000;"&gt;// Assume the following mapping table:&lt;/SPAN&gt; &lt;/P&gt;&lt;P&gt;&lt;SPAN style="color: #000000;"&gt;map1:&lt;/SPAN&gt; &lt;/P&gt;&lt;P&gt;&lt;SPAN style="color: #000000;"&gt;mapping load * inline [&lt;/SPAN&gt; &lt;/P&gt;&lt;P&gt;&lt;SPAN style="color: #000000;"&gt;x, y&lt;/SPAN&gt; &lt;/P&gt;&lt;P&gt;&lt;SPAN style="color: #000000;"&gt;1, &amp;lt;one&amp;gt;&lt;/SPAN&gt; &lt;/P&gt;&lt;P&gt;&lt;SPAN style="color: #000000;"&gt;aa, XYZ&lt;/SPAN&gt; &lt;/P&gt;&lt;P&gt;&lt;SPAN style="color: #000000;"&gt;x, b ] ;&lt;/SPAN&gt; &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;TABLE cellspacing="0" style="margin-top: 14pt; width: 450px; margin-left: 80px;" width="450"&gt;&lt;TBODY&gt;&lt;TR&gt;&lt;TD style="width: 51%; padding: 7px;" valign="top" width="51%"&gt;&lt;P&gt;&lt;SPAN class="Bold"&gt;MapSubstring ( 'map1', 'A123' )&lt;/SPAN&gt; &lt;/P&gt;&lt;/TD&gt;&lt;TD style="width: 23%; padding: 7px;" valign="top" width="23%"&gt;&lt;P&gt;returns&lt;/P&gt;&lt;/TD&gt;&lt;TD style="width: 26%; padding: 7px;" valign="top" width="26%"&gt;&lt;P&gt;&lt;SPAN class="Bold"&gt;' A&amp;lt;one&amp;gt;23'&lt;/SPAN&gt; &lt;/P&gt;&lt;/TD&gt;&lt;/TR&gt;&lt;TR&gt;&lt;TD style="width: 51%; padding: 7px;" valign="top" width="51%"&gt;&lt;P&gt;&lt;SPAN class="Bold"&gt;MapSubstring ( 'map1', 'baaar' )&lt;/SPAN&gt; &lt;/P&gt;&lt;/TD&gt;&lt;TD style="width: 23%; padding: 7px;" valign="top" width="23%"&gt;&lt;P&gt;returns&lt;/P&gt;&lt;/TD&gt;&lt;TD style="width: 26%; padding: 7px;" valign="top" width="26%"&gt;&lt;P&gt;&lt;SPAN class="Bold"&gt;' bXYZar'&lt;/SPAN&gt; &lt;/P&gt;&lt;/TD&gt;&lt;/TR&gt;&lt;TR&gt;&lt;TD style="width: 51%; padding: 7px;" valign="top" width="51%"&gt;&lt;P&gt;&lt;SPAN class="Bold"&gt;MapSubstring ( 'map1', 'xaa1' )&lt;/SPAN&gt; &lt;/P&gt;&lt;/TD&gt;&lt;TD style="width: 23%; padding: 7px;" valign="top" width="23%"&gt;&lt;P&gt;returns&lt;/P&gt;&lt;/TD&gt;&lt;TD style="width: 26%; padding: 7px;" valign="top" width="26%"&gt;&lt;P&gt;&lt;SPAN class="Bold"&gt;' bXYZ&amp;lt;one&amp;gt;'&lt;/SPAN&gt; &lt;/P&gt;&lt;/TD&gt;&lt;/TR&gt;&lt;/TBODY&gt;&lt;/TABLE&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 14 Nov 2011 17:20:30 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/replace-question/m-p/318282#M117320</guid>
      <dc:creator>swuehl</dc:creator>
      <dc:date>2011-11-14T17:20:30Z</dc:date>
    </item>
    <item>
      <title>replace question</title>
      <link>https://community.qlik.com/t5/QlikView/replace-question/m-p/318283#M117321</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt; Try working on this basic script:&lt;/P&gt;&lt;P&gt;&lt;SPAN style="color: #0000ff; font-size: 8pt;"&gt; &lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="color: #0000ff; font-size: 8pt;"&gt; &lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;USA_Map:&lt;BR /&gt;LOAD * INLINE [&lt;BR /&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; Value, New_Value&lt;BR /&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; America, USA&lt;BR /&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; USA, USA&lt;BR /&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; US, USA&lt;BR /&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; United States, USA&lt;BR /&gt;];&lt;/P&gt;&lt;P&gt;Data:&lt;BR /&gt;LOAD Value,&lt;BR /&gt; ApplyMap('USA_Map',Value,Value) as New_Mapped_Value&lt;BR /&gt;FROM&lt;BR /&gt;[..\Data.xls]&lt;BR /&gt;(biff, embedded labels, table is Sheet1$);&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;First Load the Mapping - 'USA_Map' - 2 columns only, the first that matches the field value you want to replace and the second (called what you want) that contains the values you want to see. Once loaded you can move on and load your data as normal but then simply apply the map to the 'text' field.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Works for me and can be as large as required.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Hope that helps,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Matt - Visual Analytics Ltd&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 14 Nov 2011 17:23:23 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/replace-question/m-p/318283#M117321</guid>
      <dc:creator>matt_crowther</dc:creator>
      <dc:date>2011-11-14T17:23:23Z</dc:date>
    </item>
    <item>
      <title>replace question</title>
      <link>https://community.qlik.com/t5/QlikView/replace-question/m-p/318284#M117322</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;@&lt;A _jive_internal="true" class="jiveTT-hover-user jive-username-link" href="https://community.qlik.com/people/swuehl" id="jive-158239725783544798838"&gt;swuehl&lt;/A&gt; .. thanks .. just what i needed&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 14 Nov 2011 18:01:47 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/replace-question/m-p/318284#M117322</guid>
      <dc:creator>amien</dc:creator>
      <dc:date>2011-11-14T18:01:47Z</dc:date>
    </item>
  </channel>
</rss>

