<?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: Column that contains HTML in QlikView</title>
    <link>https://community.qlik.com/t5/QlikView/Column-that-contains-HTML/m-p/553729#M206880</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;In addition, I recognized some spaces between tags in your example: &lt;STRONG&gt;&amp;lt;/font&amp;gt;_&amp;lt;br&amp;gt; &lt;/STRONG&gt;and &lt;STRONG&gt;&amp;lt;/font&amp;gt;_&amp;lt;/font&amp;gt;&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;To get rid of this it should be fixed before with a replace like this: replace(Field, '&amp;gt; &amp;lt;', '&amp;gt;&amp;lt;')&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Tue, 10 Dec 2013 14:54:31 GMT</pubDate>
    <dc:creator>rbecher</dc:creator>
    <dc:date>2013-12-10T14:54:31Z</dc:date>
    <item>
      <title>Column that contains HTML</title>
      <link>https://community.qlik.com/t5/QlikView/Column-that-contains-HTML/m-p/553727#M206878</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hello,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;is it possible to eliminate the html-tags from a column that contains following values:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;BR /&gt; &amp;lt;html&amp;gt;&amp;lt;body&amp;gt;&amp;lt;br&amp;gt;&amp;lt;font color="#000080"&amp;gt;&amp;lt;b&amp;gt;&lt;STRONG&gt;test&lt;/STRONG&gt;:&amp;lt;/b&amp;gt;&amp;lt;/font&amp;gt; &amp;lt;br&amp;gt;&amp;lt;br&amp;gt;&amp;lt;font color="#000080"&amp;gt;&amp;lt;b&amp;gt;&lt;STRONG&gt;draft&lt;/STRONG&gt;&amp;lt;/b&amp;gt;&amp;lt;/font&amp;gt; &amp;lt;/font&amp;gt;&amp;lt;/body&amp;gt;&amp;lt;/html&amp;gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I want that only test and draft is being showed in the column after removing the tags.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thanks for your help!&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Best regards,&lt;/P&gt;&lt;P&gt;Aylin&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 10 Dec 2013 14:16:33 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Column-that-contains-HTML/m-p/553727#M206878</guid>
      <dc:creator />
      <dc:date>2013-12-10T14:16:33Z</dc:date>
    </item>
    <item>
      <title>Re: Column that contains HTML</title>
      <link>https://community.qlik.com/t5/QlikView/Column-that-contains-HTML/m-p/553728#M206879</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;this is an example how to strip HTML tags:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;PRE __default_attr="plain" __jive_macro_name="code" class="jive_text_macro jive_macro_code _jivemacro_uid_13866866837736813" jivemacro_uid="_13866866837736813" modifiedtitle="true"&gt;
&lt;P class="line"&gt;Data:&lt;/P&gt;
&lt;P class="line"&gt;LOAD RecNo() as RecNo, Field&lt;/P&gt;
&lt;P class="line"&gt;FROM &amp;lt;your source file&amp;gt;;&lt;/P&gt;
&lt;P class="line"&gt;&lt;/P&gt;
&lt;P class="line"&gt;HtmlTag_Map:&lt;/P&gt;
&lt;P class="line"&gt;MAPPING LOAD DISTINCT '&amp;lt;' &amp;amp; TextBetween('&amp;lt;' &amp;amp; SubField(Field, '&amp;lt;', IterNo()),'&amp;lt;','&amp;gt;') &amp;amp; '&amp;gt;' as HtmlTag, '' as Substitute&lt;/P&gt;
&lt;P class="line"&gt;Resident Data&lt;/P&gt;
&lt;P class="line"&gt;While NOT IsNull(SubField(Field, '&amp;lt;', IterNo()));&lt;/P&gt;
&lt;P class="line"&gt;&lt;/P&gt;
&lt;P class="line"&gt;JOIN(Data) LOAD RecNo, MapSubstring('HtmlTag_Map', Field) as Field_Cleansed&lt;/P&gt;
&lt;P class="line"&gt;Resident Data;&lt;/P&gt;
&lt;/PRE&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;It looks a bit complex but it's easy to adapt. There are three steps:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;1. Load the field with HTML tags&lt;/P&gt;&lt;P&gt;2. Create a Mapping Table containing all in data existing HTML tags&lt;/P&gt;&lt;P&gt;3. Use MapSunstring to replace the existing HTML tags with empty string&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;- Ralf&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;PS: this example is also released on my GiiHub/Gist account&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 10 Dec 2013 14:48:46 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Column-that-contains-HTML/m-p/553728#M206879</guid>
      <dc:creator>rbecher</dc:creator>
      <dc:date>2013-12-10T14:48:46Z</dc:date>
    </item>
    <item>
      <title>Re: Column that contains HTML</title>
      <link>https://community.qlik.com/t5/QlikView/Column-that-contains-HTML/m-p/553729#M206880</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;In addition, I recognized some spaces between tags in your example: &lt;STRONG&gt;&amp;lt;/font&amp;gt;_&amp;lt;br&amp;gt; &lt;/STRONG&gt;and &lt;STRONG&gt;&amp;lt;/font&amp;gt;_&amp;lt;/font&amp;gt;&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;To get rid of this it should be fixed before with a replace like this: replace(Field, '&amp;gt; &amp;lt;', '&amp;gt;&amp;lt;')&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 10 Dec 2013 14:54:31 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Column-that-contains-HTML/m-p/553729#M206880</guid>
      <dc:creator>rbecher</dc:creator>
      <dc:date>2013-12-10T14:54:31Z</dc:date>
    </item>
  </channel>
</rss>

