<?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. :Re: Help using Count function in QlikView</title>
    <link>https://community.qlik.com/t5/QlikView/Help-using-Count-function/m-p/177468#M45070</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Qlikview use an associative model to store data , every occurence of each field is stored only one time , so when we use count ( partno ) , the bahavior is like count(distinct partno). try also to add a column with 1 as value for all rows and do a sum() to this field .&lt;/P&gt;&lt;P&gt;ex:&lt;/P&gt;&lt;P&gt;load month ,&lt;/P&gt;&lt;P&gt;partno ,&lt;/P&gt;&lt;P&gt;1 ;&lt;/P&gt;&lt;P&gt;hope that it will help&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Mon, 07 Jun 2010 11:00:32 GMT</pubDate>
    <dc:creator />
    <dc:date>2010-06-07T11:00:32Z</dc:date>
    <item>
      <title>Help using Count function</title>
      <link>https://community.qlik.com/t5/QlikView/Help-using-Count-function/m-p/177463#M45065</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;&lt;/P&gt;&lt;P dir="ltr"&gt;Hi guys,&lt;/P&gt;&lt;P dir="ltr"&gt;I need to calculate the average of Parts that appear every month, (I should count also those parts that appears in more than 1 month)&lt;/P&gt;&lt;P dir="ltr"&gt;In example:&lt;/P&gt;&lt;P dir="ltr"&gt;Month PartNo&lt;/P&gt;&lt;P dir="ltr"&gt;2010-01 &lt;B&gt;Part1&lt;/B&gt; &lt;B&gt;&lt;/B&gt;&lt;/P&gt;&lt;P dir="ltr"&gt;2010-01 Part2&lt;/P&gt;&lt;P dir="ltr"&gt;2010-01 Part3&lt;/P&gt;&lt;P dir="ltr"&gt;2010-01 Part4 Total Count for 2010-01 =&amp;gt; &lt;B&gt;4&lt;/B&gt;&lt;/P&gt;&lt;P dir="ltr"&gt;&lt;/P&gt;&lt;P dir="ltr"&gt;2010-02 &lt;B&gt;Part1&lt;/B&gt; &lt;B&gt;&lt;/B&gt;&lt;/P&gt;&lt;P dir="ltr"&gt;2010-02 Part10&lt;/P&gt;&lt;P dir="ltr"&gt;2010-02 Part11&lt;/P&gt;&lt;P dir="ltr"&gt;2010-02 Part12&lt;/P&gt;&lt;P dir="ltr"&gt;2010-02 Part13&lt;/P&gt;&lt;P dir="ltr"&gt;2010-02 Part14 Total Count for 2010-02 ==&amp;gt; &lt;B&gt;6&lt;/B&gt;&lt;/P&gt;&lt;P dir="ltr"&gt;&lt;/P&gt;&lt;P dir="ltr"&gt;Total Count for 2010-01 + 2010-02 ==&amp;gt; &lt;B&gt;10&lt;/B&gt;&lt;/P&gt;&lt;P dir="ltr"&gt;Average should be ==&amp;gt; 10/2 = &lt;B&gt;5&lt;/B&gt;&lt;/P&gt;&lt;P dir="ltr"&gt;&lt;/P&gt;&lt;P dir="ltr"&gt;The problem is that using = &lt;B&gt;Count&lt;/B&gt;( &lt;B&gt;[Part No]&lt;/B&gt;) gives me &lt;B&gt;9&lt;/B&gt;, because Part1 appears twice.&lt;/P&gt;&lt;P dir="ltr"&gt;How can I work it around?&lt;/P&gt;&lt;P dir="ltr"&gt;Thanks in advance,&lt;/P&gt;&lt;P dir="ltr"&gt;Aldo.&lt;/P&gt;&lt;P dir="ltr"&gt;&lt;/P&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Sun, 06 Jun 2010 14:50:09 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Help-using-Count-function/m-p/177463#M45065</guid>
      <dc:creator />
      <dc:date>2010-06-06T14:50:09Z</dc:date>
    </item>
    <item>
      <title>Help using Count function</title>
      <link>https://community.qlik.com/t5/QlikView/Help-using-Count-function/m-p/177464#M45066</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;hi aldo,&lt;/P&gt;&lt;P&gt;first concatenate your month and part no in your script itself somewhat like this&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;tab1:&lt;/P&gt;&lt;P&gt;load Month&amp;amp;','&amp;amp;PartNo as column;&lt;/P&gt;&lt;P&gt;load *inline[&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P dir="ltr"&gt;Month PartNo&lt;/P&gt;&lt;P dir="ltr"&gt;2010-01 Part1 &lt;B&gt;&lt;/B&gt;&lt;/P&gt;&lt;P dir="ltr"&gt;2010-01 Part2&lt;/P&gt;&lt;P dir="ltr"&gt;2010-01 Part3&lt;/P&gt;&lt;P dir="ltr"&gt;2010-01 Part4&lt;/P&gt;&lt;P dir="ltr"&gt;2010-02 &lt;B&gt;&lt;/B&gt; Part1 &lt;B&gt;&lt;/B&gt;&lt;/P&gt;&lt;P dir="ltr"&gt;&lt;/P&gt;&lt;P dir="ltr"&gt;2010-02 Part10&lt;/P&gt;&lt;P dir="ltr"&gt;2010-02 Part11&lt;/P&gt;&lt;P dir="ltr"&gt;2010-02 Part12&lt;/P&gt;&lt;P dir="ltr"&gt;2010-02 Part13&lt;/P&gt;&lt;P dir="ltr"&gt;2010-02 Part14&lt;/P&gt;&lt;P dir="ltr"&gt;];&lt;/P&gt;&lt;P dir="ltr"&gt;&lt;/P&gt;&lt;P dir="ltr"&gt;and then use&lt;/P&gt;&lt;P dir="ltr"&gt;load count(mid(column,index(column,',')+1)) as mycount resident tab1;&lt;/P&gt;&lt;BR /&gt;&lt;BR /&gt; &lt;P dir="ltr"&gt;&lt;/P&gt;&lt;P dir="ltr"&gt;thanks&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Sun, 06 Jun 2010 17:16:24 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Help-using-Count-function/m-p/177464#M45066</guid>
      <dc:creator />
      <dc:date>2010-06-06T17:16:24Z</dc:date>
    </item>
    <item>
      <title>Help using Count function</title>
      <link>https://community.qlik.com/t5/QlikView/Help-using-Count-function/m-p/177465#M45067</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi Aldo!&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;How about using = Count( distinct [Part No]).&lt;/P&gt;&lt;P&gt;That should work..&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;-Lester&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 07 Jun 2010 04:49:40 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Help-using-Count-function/m-p/177465#M45067</guid>
      <dc:creator />
      <dc:date>2010-06-07T04:49:40Z</dc:date>
    </item>
    <item>
      <title>Help using Count function</title>
      <link>https://community.qlik.com/t5/QlikView/Help-using-Count-function/m-p/177466#M45068</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Concatenating Month with PartNo was the solution I was looking for.&lt;/P&gt;&lt;P&gt;Thanks,&lt;/P&gt;&lt;P&gt;Aldo.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 07 Jun 2010 10:50:42 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Help-using-Count-function/m-p/177466#M45068</guid>
      <dc:creator />
      <dc:date>2010-06-07T10:50:42Z</dc:date>
    </item>
    <item>
      <title>Help using Count function</title>
      <link>https://community.qlik.com/t5/QlikView/Help-using-Count-function/m-p/177467#M45069</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi Lester,&lt;/P&gt;&lt;P&gt;I tried Count(Distinct...), but it didn't work.&lt;/P&gt;&lt;P&gt;Thanks,&lt;/P&gt;&lt;P&gt;Aldo.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 07 Jun 2010 10:51:49 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Help-using-Count-function/m-p/177467#M45069</guid>
      <dc:creator />
      <dc:date>2010-06-07T10:51:49Z</dc:date>
    </item>
    <item>
      <title>Re. :Re: Help using Count function</title>
      <link>https://community.qlik.com/t5/QlikView/Help-using-Count-function/m-p/177468#M45070</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Qlikview use an associative model to store data , every occurence of each field is stored only one time , so when we use count ( partno ) , the bahavior is like count(distinct partno). try also to add a column with 1 as value for all rows and do a sum() to this field .&lt;/P&gt;&lt;P&gt;ex:&lt;/P&gt;&lt;P&gt;load month ,&lt;/P&gt;&lt;P&gt;partno ,&lt;/P&gt;&lt;P&gt;1 ;&lt;/P&gt;&lt;P&gt;hope that it will help&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 07 Jun 2010 11:00:32 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Help-using-Count-function/m-p/177468#M45070</guid>
      <dc:creator />
      <dc:date>2010-06-07T11:00:32Z</dc:date>
    </item>
    <item>
      <title>Re. :Re: Help using Count function</title>
      <link>https://community.qlik.com/t5/QlikView/Help-using-Count-function/m-p/177469#M45071</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Thanks for your explanation.&lt;/P&gt;&lt;P&gt;Aldo.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 07 Jun 2010 14:43:48 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Help-using-Count-function/m-p/177469#M45071</guid>
      <dc:creator />
      <dc:date>2010-06-07T14:43:48Z</dc:date>
    </item>
  </channel>
</rss>

