<?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: Substring Count in QlikView</title>
    <link>https://community.qlik.com/t5/QlikView/Substring-Count/m-p/1670488#M723352</link>
    <description>&lt;P&gt;Yes , the else condition was wrong and it's modified. But the logic which have written to find the junk characters is not working properly.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
    <pubDate>Wed, 29 Jan 2020 13:48:04 GMT</pubDate>
    <dc:creator>krishna20</dc:creator>
    <dc:date>2020-01-29T13:48:04Z</dc:date>
    <item>
      <title>Substring Count</title>
      <link>https://community.qlik.com/t5/QlikView/Substring-Count/m-p/1668998#M723347</link>
      <description>&lt;P&gt;Hi Folks,&lt;/P&gt;&lt;P&gt;I have data like below and expected output as given.&lt;/P&gt;&lt;P&gt;I am using substring count to achieve this, but not getting expected result. Somewhere going wrong, Could anyone please look into this and advise.&lt;/P&gt;&lt;TABLE&gt;&lt;TBODY&gt;&lt;TR&gt;&lt;TD&gt;Error_Count&lt;/TD&gt;&lt;TD&gt;Count&lt;/TD&gt;&lt;/TR&gt;&lt;TR&gt;&lt;TD&gt;.,Kalyan&lt;/TD&gt;&lt;TD&gt;2&lt;/TD&gt;&lt;/TR&gt;&lt;TR&gt;&lt;TD&gt;&lt;A href="mailto:Uday@Gmail.com" target="_blank" rel="noopener"&gt;Uday@Gmail.com&lt;/A&gt;&lt;/TD&gt;&lt;TD&gt;1&lt;/TD&gt;&lt;/TR&gt;&lt;TR&gt;&lt;TD&gt;Uday.,&lt;/TD&gt;&lt;TD&gt;2&lt;/TD&gt;&lt;/TR&gt;&lt;TR&gt;&lt;TD&gt;Kalyan_krishna&lt;/TD&gt;&lt;TD&gt;1&lt;/TD&gt;&lt;/TR&gt;&lt;TR&gt;&lt;TD&gt;Gopi23&lt;/TD&gt;&lt;TD&gt;2&lt;/TD&gt;&lt;/TR&gt;&lt;TR&gt;&lt;TD&gt;(krishna&lt;/TD&gt;&lt;TD&gt;1&lt;/TD&gt;&lt;/TR&gt;&lt;/TBODY&gt;&lt;/TABLE&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Load* ,&lt;BR /&gt;If(&lt;BR /&gt;( Substringcount(Error_Count, '.')&lt;BR /&gt;+Substringcount(Error_Count, ',')&lt;BR /&gt;+ Substringcount(Error_Count, '@')&lt;BR /&gt;+ Substringcount(Error_Count, '_')&lt;BR /&gt;+ Substringcount(Error_Count, '2')&lt;BR /&gt;+ Substringcount(Error_Count, '3')&lt;BR /&gt;+ Substringcount(Error_Count, '(')&lt;BR /&gt;),1,0) as Count;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Regards&lt;/P&gt;&lt;P&gt;Krishna&lt;/P&gt;</description>
      <pubDate>Sat, 16 Nov 2024 19:14:10 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Substring-Count/m-p/1668998#M723347</guid>
      <dc:creator>krishna20</dc:creator>
      <dc:date>2024-11-16T19:14:10Z</dc:date>
    </item>
    <item>
      <title>Re: Substring Count</title>
      <link>https://community.qlik.com/t5/QlikView/Substring-Count/m-p/1669014#M723348</link>
      <description>&lt;P&gt;Maybe this approach using &lt;A href="https://help.qlik.com/en-US/qlikview/April2019/Subsystems/Client/Content/QV_QlikView/Scripting/StringFunctions/KeepChar.htm" target="_self"&gt;KeepChar()&lt;/A&gt; could help you?&lt;/P&gt;&lt;LI-CODE lang="ruby"&gt;LOAD 
	Error_Count,
	Count as [Desired count], 
	len(KeepChar(Error_Count,'.,@_23(')) as [Calculated count] 
inline [
	Error_Count	Count
	.,Kalyan	2
	Uday@Gmail.com	1
	Uday.,	2
	Kalyan_krishna	1
	Gopi23	2
	(krishna	1
] (delimiter is '	');&lt;/LI-CODE&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Notice that the "Uday@Gmail.com" counts 2 not 1 as in your table as it contains both . and&amp;nbsp;@.&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="image.png" style="width: 607px;"&gt;&lt;img src="https://community.qlik.com/t5/image/serverpage/image-id/27429iC5EB4EA828B7617B/image-size/large?v=v2&amp;amp;px=999" role="button" title="image.png" alt="image.png" /&gt;&lt;/span&gt;&lt;/P&gt;</description>
      <pubDate>Fri, 24 Jan 2020 14:47:15 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Substring-Count/m-p/1669014#M723348</guid>
      <dc:creator>Vegar</dc:creator>
      <dc:date>2020-01-24T14:47:15Z</dc:date>
    </item>
    <item>
      <title>Re: Substring Count</title>
      <link>https://community.qlik.com/t5/QlikView/Substring-Count/m-p/1669018#M723349</link>
      <description>&lt;P&gt;Get rid of the IF and the 0,1:&lt;/P&gt;&lt;P&gt;Substringcount(Error_Count, '.')&lt;BR /&gt;+ Substringcount(Error_Count, ',')&lt;BR /&gt;+ Substringcount(Error_Count, '@')&lt;BR /&gt;+ Substringcount(Error_Count, '_')&lt;BR /&gt;+ Substringcount(Error_Count, '2')&lt;BR /&gt;+ Substringcount(Error_Count, '3')&lt;BR /&gt;+ Substringcount(Error_Count, '(') as Count&lt;/P&gt;</description>
      <pubDate>Fri, 24 Jan 2020 14:56:11 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Substring-Count/m-p/1669018#M723349</guid>
      <dc:creator>m_woolf</dc:creator>
      <dc:date>2020-01-24T14:56:11Z</dc:date>
    </item>
    <item>
      <title>Re: Substring Count</title>
      <link>https://community.qlik.com/t5/QlikView/Substring-Count/m-p/1669039#M723350</link>
      <description>&lt;P&gt;Hi vegar,&lt;/P&gt;&lt;P&gt;Thanks for your reply. Actually the substring count flag is not showing right sum . Please look into below script and scenario and advise.&lt;/P&gt;&lt;P&gt;Load&amp;nbsp;&lt;/P&gt;&lt;P&gt;If(Match(Left([Error_Count],1),'.',',','\','1','2','3','4','5','6','7','8','9','0','@','*','#','$','!','%','^','&amp;amp;','(',')',';','?','+','=','{','}','[',']','~','`','/',':','&amp;lt;','&amp;gt;','_')&lt;BR /&gt;or Match(Mid([Error_Count],1),',','\','1','2','3','4','5','6','7','8','9','0','@','*','#','$','!','%','^','&amp;amp;','(',')',';','?','+','=','{','}','[',']','~','`','/',':','&amp;lt;','&amp;gt;','_')&lt;BR /&gt;or Match(Right([Error_Count],1),'\','1','2','3','4','5','6','7','8','9','0','@','*','#','$','!','%','^','&amp;amp;','(',')','?','+','=','{','}','[',']','~','`','/',':','&amp;lt;','&amp;gt;','_'),&lt;BR /&gt;( Substringcount([Error_Count], '.')&lt;BR /&gt;&amp;nbsp;+Substringcount([Error_Count], ',')&lt;BR /&gt;+ Substringcount([Error_Count], '@')&lt;BR /&gt;+ Substringcount([Error_Count], '1')&lt;BR /&gt;+ Substringcount([Error_Count], '2')&lt;/P&gt;&lt;P&gt;+ Substringcount([Error_Count], '&amp;lt;')&lt;/P&gt;&lt;P&gt;+ Substringcount([Error_Count], '&amp;gt;')&lt;/P&gt;&lt;P&gt;+ Substringcount([Error_Count], '_')&lt;BR /&gt;as , ,'.,\1234567890@*#$!%^&amp;amp;()?+={}[]~`/:&amp;lt;&amp;gt;_'))) as Error_Count;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;It creates a flag with different numbers.&lt;/P&gt;&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="Comm_Flag.PNG" style="width: 553px;"&gt;&lt;img src="https://community.qlik.com/t5/image/serverpage/image-id/27433i8749B3C65B361573/image-size/large?v=v2&amp;amp;px=999" role="button" title="Comm_Flag.PNG" alt="Comm_Flag.PNG" /&gt;&lt;/span&gt;&lt;/P&gt;&lt;P&gt;But When I sum this flag in straight table, the calculation&lt;/P&gt;&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="Comm_Error.PNG" style="width: 598px;"&gt;&lt;img src="https://community.qlik.com/t5/image/serverpage/image-id/27436iA9BC3554F523C045/image-size/large?v=v2&amp;amp;px=999" role="button" title="Comm_Error.PNG" alt="Comm_Error.PNG" /&gt;&lt;/span&gt;&lt;/P&gt;&lt;P&gt;The count suppose to show 6 but it's showing 234 and many are there like this.&amp;nbsp;&lt;/P&gt;&lt;P&gt;The Highlighted name has ,.&amp;lt;@.&amp;gt; and count should show as 6.&lt;/P&gt;</description>
      <pubDate>Fri, 24 Jan 2020 15:17:02 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Substring-Count/m-p/1669039#M723350</guid>
      <dc:creator>krishna20</dc:creator>
      <dc:date>2020-01-24T15:17:02Z</dc:date>
    </item>
    <item>
      <title>Re: Substring Count</title>
      <link>https://community.qlik.com/t5/QlikView/Substring-Count/m-p/1669287#M723351</link>
      <description>&lt;P&gt;By the looks of your screenshot it looks strange. Could it be that you have multiple transactions with that email adress? (234/6 =39)&lt;/P&gt;&lt;P&gt;I also noticed something odd in your expression, is the yellow marking made by me correct?&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="image.png" style="width: 851px;"&gt;&lt;img src="https://community.qlik.com/t5/image/serverpage/image-id/27477iD9C15B843254A89B/image-size/large?v=v2&amp;amp;px=999" role="button" title="image.png" alt="image.png" /&gt;&lt;/span&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;You could also try to break out parts of our expression in order to identify which part of the expression is generating the large value.&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;/Vegar&lt;/P&gt;</description>
      <pubDate>Mon, 27 Jan 2020 08:20:14 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Substring-Count/m-p/1669287#M723351</guid>
      <dc:creator>Vegar</dc:creator>
      <dc:date>2020-01-27T08:20:14Z</dc:date>
    </item>
    <item>
      <title>Re: Substring Count</title>
      <link>https://community.qlik.com/t5/QlikView/Substring-Count/m-p/1670488#M723352</link>
      <description>&lt;P&gt;Yes , the else condition was wrong and it's modified. But the logic which have written to find the junk characters is not working properly.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Wed, 29 Jan 2020 13:48:04 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Substring-Count/m-p/1670488#M723352</guid>
      <dc:creator>krishna20</dc:creator>
      <dc:date>2020-01-29T13:48:04Z</dc:date>
    </item>
  </channel>
</rss>

