<?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: Set analysis date range in QlikView</title>
    <link>https://community.qlik.com/t5/QlikView/Set-analysis-date-range/m-p/1218852#M863462</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;I don't see any issues with using this, but from the looks of the things, it seems that your Fiscal Year Month field is not interpreted as a date field? May be do like this in the script:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;LOAD Date(&lt;/STRONG&gt;&lt;SPAN style="color: #3d3d3d; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; font-size: 13px;"&gt;&lt;STRONG&gt;Date#([Fiscal Year Month]), 'YYYY-MM')&lt;SPAN style="color: #3d3d3d; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; font-size: 13px;"&gt;, 'YYYY-MM')&lt;/SPAN&gt; as &lt;/STRONG&gt;&lt;SPAN style="color: #3d3d3d; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; font-size: 13px;"&gt;&lt;STRONG&gt;[Fiscal Year Month]&lt;/STRONG&gt;&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;and then try your expression as is&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P style="font-size: 13px; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; color: #3d3d3d;"&gt;&lt;STRONG&gt;Sum({$&amp;lt;&lt;/STRONG&gt;&lt;STRONG&gt;[Fiscal Year Month] = {"&amp;gt;=$(=Date(AddMonths(Max(Today()),-8), 'YYYY-MM'))&amp;lt;=$(=Date(AddMonths(Max(Today()),-2), 'YYYY-MM'))"}&lt;/STRONG&gt;&lt;STRONG&gt;&amp;gt;} [Record Count])&lt;/STRONG&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Wed, 21 Dec 2016 16:03:21 GMT</pubDate>
    <dc:creator>sunny_talwar</dc:creator>
    <dc:date>2016-12-21T16:03:21Z</dc:date>
    <item>
      <title>Set analysis date range</title>
      <link>https://community.qlik.com/t5/QlikView/Set-analysis-date-range/m-p/1218846#M863454</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;I cannot understand why the below expression doesnt work&lt;/P&gt;&lt;P&gt; Sum({$&amp;lt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; [Fiscal Year Month] ={"&amp;gt;=$(=Date(AddMonths(Max(Today()),-8), 'YYYY-MM')) &amp;lt;=$(=Date(AddMonths(Max(Today()),-2), 'YYYY-MM'))"}&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;gt;} [Record Count])&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;The below does work.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Sum({&amp;lt; &lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; [Fiscal Year Month] = {"$(=Date(AddMonths(Max(Today()), -1), 'YYYY-MM'))"}&amp;gt;}&lt;/P&gt;&lt;P&gt;&amp;nbsp; [Record Count])&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;as i get the required figure.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I get 0 for&lt;/P&gt;&lt;P&gt; Sum({$&amp;lt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; [Fiscal Year Month] ={"&amp;gt;=$(=Date(AddMonths(Max(Today()),-8), 'YYYY-MM')) &amp;lt;=$(=Date(AddMonths(Max(Today()),-2), 'YYYY-MM'))"}&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;gt;} [Record Count])&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Any one see the issue?&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 25 Nov 2020 16:16:04 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Set-analysis-date-range/m-p/1218846#M863454</guid>
      <dc:creator>bobbydave</dc:creator>
      <dc:date>2020-11-25T16:16:04Z</dc:date>
    </item>
    <item>
      <title>Re: Set analysis date range</title>
      <link>https://community.qlik.com/t5/QlikView/Set-analysis-date-range/m-p/1218847#M863455</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Do you have other date related fields where you might be making selections? Like Fiscal Month or something along those lines? If you do, then you need to ignore selections in those fields and let your Fiscal Year Month indirectly drive your selections in other date related fields&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 21 Dec 2016 15:49:43 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Set-analysis-date-range/m-p/1218847#M863455</guid>
      <dc:creator>sunny_talwar</dc:creator>
      <dc:date>2016-12-21T15:49:43Z</dc:date>
    </item>
    <item>
      <title>Re: Set analysis date range</title>
      <link>https://community.qlik.com/t5/QlikView/Set-analysis-date-range/m-p/1218848#M863456</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;These dates for back to 2015-01 if thats what you mean.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;If i use the working example of last month record count and then get today()-8, i will get the correct answer.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Its when i sum &amp;gt;= today() -8 and&amp;nbsp; today() -2 which is my issue.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 21 Dec 2016 15:51:53 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Set-analysis-date-range/m-p/1218848#M863456</guid>
      <dc:creator>bobbydave</dc:creator>
      <dc:date>2016-12-21T15:51:53Z</dc:date>
    </item>
    <item>
      <title>Re: Set analysis date range</title>
      <link>https://community.qlik.com/t5/QlikView/Set-analysis-date-range/m-p/1218849#M863458</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;That's not what I meant, I think.... Are you making any selections when it is not working? or is it not working regardless of any selection made or not?&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 21 Dec 2016 15:55:52 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Set-analysis-date-range/m-p/1218849#M863458</guid>
      <dc:creator>sunny_talwar</dc:creator>
      <dc:date>2016-12-21T15:55:52Z</dc:date>
    </item>
    <item>
      <title>Re: Set analysis date range</title>
      <link>https://community.qlik.com/t5/QlikView/Set-analysis-date-range/m-p/1218850#M863459</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Also, I was told before not to use 'AND' in set analysis&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Sum({&amp;lt; &lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; [Fiscal Year Month]= {"=Date#(Only({&amp;lt;[Fiscal Year Month]&amp;gt;}[Fiscal Year Month]), 'YYYY-MM') &amp;gt;= AddMonths(Today(), -8) &lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;STRONG&gt;and&lt;/STRONG&gt; Date#(Only({&amp;lt;[Fiscal Year Month]&amp;gt;}[Fiscal Year Month]), 'YYYY-MM') &amp;lt;= AddMonths(Today(), -2)"}&amp;gt;} &lt;/P&gt;&lt;P&gt;&amp;nbsp; [Record Count])&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;This however, does give me a figure which could be right. But i am dubious to use the expression if it is not proper procedure to use AND in set analysis.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 21 Dec 2016 15:57:08 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Set-analysis-date-range/m-p/1218850#M863459</guid>
      <dc:creator>bobbydave</dc:creator>
      <dc:date>2016-12-21T15:57:08Z</dc:date>
    </item>
    <item>
      <title>Re: Set analysis date range</title>
      <link>https://community.qlik.com/t5/QlikView/Set-analysis-date-range/m-p/1218851#M863461</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Apologies for my misinterpretation.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;No selections have been made.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;It will always be these dates being used today -8 and today -2.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;It is to be used in a condition for an Alert&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 21 Dec 2016 15:59:28 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Set-analysis-date-range/m-p/1218851#M863461</guid>
      <dc:creator>bobbydave</dc:creator>
      <dc:date>2016-12-21T15:59:28Z</dc:date>
    </item>
    <item>
      <title>Re: Set analysis date range</title>
      <link>https://community.qlik.com/t5/QlikView/Set-analysis-date-range/m-p/1218852#M863462</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;I don't see any issues with using this, but from the looks of the things, it seems that your Fiscal Year Month field is not interpreted as a date field? May be do like this in the script:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;LOAD Date(&lt;/STRONG&gt;&lt;SPAN style="color: #3d3d3d; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; font-size: 13px;"&gt;&lt;STRONG&gt;Date#([Fiscal Year Month]), 'YYYY-MM')&lt;SPAN style="color: #3d3d3d; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; font-size: 13px;"&gt;, 'YYYY-MM')&lt;/SPAN&gt; as &lt;/STRONG&gt;&lt;SPAN style="color: #3d3d3d; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; font-size: 13px;"&gt;&lt;STRONG&gt;[Fiscal Year Month]&lt;/STRONG&gt;&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;and then try your expression as is&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P style="font-size: 13px; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; color: #3d3d3d;"&gt;&lt;STRONG&gt;Sum({$&amp;lt;&lt;/STRONG&gt;&lt;STRONG&gt;[Fiscal Year Month] = {"&amp;gt;=$(=Date(AddMonths(Max(Today()),-8), 'YYYY-MM'))&amp;lt;=$(=Date(AddMonths(Max(Today()),-2), 'YYYY-MM'))"}&lt;/STRONG&gt;&lt;STRONG&gt;&amp;gt;} [Record Count])&lt;/STRONG&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 21 Dec 2016 16:03:21 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Set-analysis-date-range/m-p/1218852#M863462</guid>
      <dc:creator>sunny_talwar</dc:creator>
      <dc:date>2016-12-21T16:03:21Z</dc:date>
    </item>
    <item>
      <title>Re: Set analysis date range</title>
      <link>https://community.qlik.com/t5/QlikView/Set-analysis-date-range/m-p/1218853#M863464</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;YEEEEESSSSSSS.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Finally.&lt;/P&gt;&lt;P&gt;FINALLY.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thank you so much.&lt;/P&gt;&lt;P&gt;It must have been a case of loading it in the script.&lt;/P&gt;&lt;P&gt;Got my value now.&lt;/P&gt;&lt;P&gt;Thanks again Sunny&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 22 Dec 2016 09:06:38 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Set-analysis-date-range/m-p/1218853#M863464</guid>
      <dc:creator>bobbydave</dc:creator>
      <dc:date>2016-12-22T09:06:38Z</dc:date>
    </item>
  </channel>
</rss>

