<?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 Set Analysis and Nulls in QlikView</title>
    <link>https://community.qlik.com/t5/QlikView/Set-Analysis-and-Nulls/m-p/174026#M42999</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi&lt;/P&gt;&lt;P&gt;In my report my set analysis expression for one pair of 'year' fields works perfectly, e.g. compare 2010 vs. 2009&lt;/P&gt;&lt;P&gt;SUM({$&amp;lt;SalesYear=CheckYear&amp;gt;} SalesVol)&lt;/P&gt;&lt;P&gt;I would like to be able to provide a facility to compare both a month and year e.g. Jan2010 vs. Mar2010. For this I used&lt;/P&gt;&lt;P&gt;SUM({$&amp;lt;SalesYear=CheckYear,SalesMonth=CheckMonth&amp;gt;} SalesVol)&lt;/P&gt;&lt;P&gt;This works fine when a year and month are both selected. However, it is very restrictive as I can no longer perform&lt;BR /&gt;the above 2010 vs. 2009 analysis because the month would be left blank.&lt;/P&gt;&lt;P&gt;I tried modifying the expression to incorporate an IF statement with IsNull logic but the set analysis syntax doesn't seem to&lt;BR /&gt;allow this.&lt;/P&gt;&lt;P&gt;Does anyone know if there is an easy way to do this without the use of variables or field content lists ? My example above is simplified from the final version where I would also like to provide similar fields for quarters, weeks and individual date comparisons !&lt;/P&gt;&lt;P&gt;Kind Regards&lt;BR /&gt;Andrew.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Wed, 02 Jun 2010 16:47:15 GMT</pubDate>
    <dc:creator>AndrewMcIlwrick</dc:creator>
    <dc:date>2010-06-02T16:47:15Z</dc:date>
    <item>
      <title>Set Analysis and Nulls</title>
      <link>https://community.qlik.com/t5/QlikView/Set-Analysis-and-Nulls/m-p/174026#M42999</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi&lt;/P&gt;&lt;P&gt;In my report my set analysis expression for one pair of 'year' fields works perfectly, e.g. compare 2010 vs. 2009&lt;/P&gt;&lt;P&gt;SUM({$&amp;lt;SalesYear=CheckYear&amp;gt;} SalesVol)&lt;/P&gt;&lt;P&gt;I would like to be able to provide a facility to compare both a month and year e.g. Jan2010 vs. Mar2010. For this I used&lt;/P&gt;&lt;P&gt;SUM({$&amp;lt;SalesYear=CheckYear,SalesMonth=CheckMonth&amp;gt;} SalesVol)&lt;/P&gt;&lt;P&gt;This works fine when a year and month are both selected. However, it is very restrictive as I can no longer perform&lt;BR /&gt;the above 2010 vs. 2009 analysis because the month would be left blank.&lt;/P&gt;&lt;P&gt;I tried modifying the expression to incorporate an IF statement with IsNull logic but the set analysis syntax doesn't seem to&lt;BR /&gt;allow this.&lt;/P&gt;&lt;P&gt;Does anyone know if there is an easy way to do this without the use of variables or field content lists ? My example above is simplified from the final version where I would also like to provide similar fields for quarters, weeks and individual date comparisons !&lt;/P&gt;&lt;P&gt;Kind Regards&lt;BR /&gt;Andrew.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 02 Jun 2010 16:47:15 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Set-Analysis-and-Nulls/m-p/174026#M42999</guid>
      <dc:creator>AndrewMcIlwrick</dc:creator>
      <dc:date>2010-06-02T16:47:15Z</dc:date>
    </item>
    <item>
      <title>Set Analysis and Nulls</title>
      <link>https://community.qlik.com/t5/QlikView/Set-Analysis-and-Nulls/m-p/174027#M43000</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi&lt;/P&gt;&lt;P&gt;can you try an empty bracket to represent the null []&lt;/P&gt;&lt;P&gt;in my trials I had to bracket the comparison values, e.g.&lt;/P&gt;&lt;P&gt;SalesMonth={CheckMonth,[]}&lt;/P&gt;&lt;P&gt;to make it work&lt;/P&gt;&lt;P&gt;Regards&lt;/P&gt;&lt;P&gt;Juerg&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 02 Jun 2010 17:06:08 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Set-Analysis-and-Nulls/m-p/174027#M43000</guid>
      <dc:creator />
      <dc:date>2010-06-02T17:06:08Z</dc:date>
    </item>
    <item>
      <title>Set Analysis and Nulls</title>
      <link>https://community.qlik.com/t5/QlikView/Set-Analysis-and-Nulls/m-p/174028#M43001</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi&lt;/P&gt;&lt;P&gt;You could try adding something into your expression to check if a month has been selected, so something like&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;BLOCKQUOTE style="overflow-x: scroll;"&gt;&lt;PRE style="margin: 0px;"&gt;IF(GetSelectedCount(CheckMonth)&amp;gt;0 , SUM({$&amp;lt;SalesYear=CheckYear,SalesMonth=CheckMonth&amp;gt;} SalesVol) , SUM({$&amp;lt;SalesYear=CheckYear&amp;gt;} SalesVol) )&lt;/PRE&gt;&lt;/BLOCKQUOTE&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 02 Jun 2010 17:07:10 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Set-Analysis-and-Nulls/m-p/174028#M43001</guid>
      <dc:creator />
      <dc:date>2010-06-02T17:07:10Z</dc:date>
    </item>
  </channel>
</rss>

