<?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: Expression not calculating correctly in QlikView</title>
    <link>https://community.qlik.com/t5/QlikView/Expression-not-calculating-correctly/m-p/387302#M144584</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;It seems that you have 5 rows for 'SMC' so count returns 5.&lt;/P&gt;&lt;P&gt;Add a tablebox and look at your data.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Sat, 08 Sep 2012 14:53:42 GMT</pubDate>
    <dc:creator>whiteline</dc:creator>
    <dc:date>2012-09-08T14:53:42Z</dc:date>
    <item>
      <title>Expression not calculating correctly</title>
      <link>https://community.qlik.com/t5/QlikView/Expression-not-calculating-correctly/m-p/387300#M144582</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi guys,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I have a field 'Date' which can have various result codes. I want to count the number of contacts in the last month. My expression is:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;sum(if(Date&amp;gt;=$(vMonthBack),if(Result='SMC',1,0),0))&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;However, this gives me the sum of ALL results, not just SMC, so long as there is one SMC in the last month. i.e. if the last month's result codes are:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;SOE, SNC, SMC, SLS, SLM, SNC, the expression returns "5" but if the last month's result codes are&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;SOE, SNC, SLM, SLM, SNC, SNC the expression returns "0". &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;What am I missing here?&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 07 Sep 2012 15:36:32 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Expression-not-calculating-correctly/m-p/387300#M144582</guid>
      <dc:creator />
      <dc:date>2012-09-07T15:36:32Z</dc:date>
    </item>
    <item>
      <title>Re: Expression not calculating correctly</title>
      <link>https://community.qlik.com/t5/QlikView/Expression-not-calculating-correctly/m-p/387301#M144583</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;This is quite difficult to follow without seeing your actual data.&amp;nbsp; Can you attach a qvw with sample data?&lt;/P&gt;&lt;P&gt;I'm pretty sure this would get you more responses.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Mark&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 07 Sep 2012 15:52:32 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Expression-not-calculating-correctly/m-p/387301#M144583</guid>
      <dc:creator>RedSky001</dc:creator>
      <dc:date>2012-09-07T15:52:32Z</dc:date>
    </item>
    <item>
      <title>Re: Expression not calculating correctly</title>
      <link>https://community.qlik.com/t5/QlikView/Expression-not-calculating-correctly/m-p/387302#M144584</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;It seems that you have 5 rows for 'SMC' so count returns 5.&lt;/P&gt;&lt;P&gt;Add a tablebox and look at your data.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Sat, 08 Sep 2012 14:53:42 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Expression-not-calculating-correctly/m-p/387302#M144584</guid>
      <dc:creator>whiteline</dc:creator>
      <dc:date>2012-09-08T14:53:42Z</dc:date>
    </item>
  </channel>
</rss>

