<?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 YTD Set Analysis in QlikView</title>
    <link>https://community.qlik.com/t5/QlikView/YTD-Set-Analysis/m-p/249498#M94817</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt; hei &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;you&amp;nbsp; can set a varaible with this formula&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;vMinDateYTD=if(num(month(vMaxDate))&amp;lt;=6,makedate(max(Year)-1,7,1),makedate(max(Year),7,1));&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;then your set analysis will be&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;sum({&amp;lt;Year,Date={'&amp;gt;=$(vMinDateYTD)&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;lt;=$(vMaxDate)'},Month=,Drawer={'4'}&amp;gt;}JrnAmt).&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Wed, 04 Jan 2012 13:34:15 GMT</pubDate>
    <dc:creator>lironbaram</dc:creator>
    <dc:date>2012-01-04T13:34:15Z</dc:date>
    <item>
      <title>YTD Set Analysis</title>
      <link>https://community.qlik.com/t5/QlikView/YTD-Set-Analysis/m-p/249497#M94816</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I have the following expression for my YTD calculation in a straight table -&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;sum({&amp;lt;Year={$(vMaxYear)},Date={'&amp;lt;=$(vMaxDate)'},Month=,Drawer={'4'}&amp;gt;}JrnAmt). The db has records from 1 July 2011 onwards so this expression works for YTD up to Dec 2011.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;The problem with this is that when the&amp;nbsp; 'Jan 2012' is selected, the total for YTD is only for 'Jan 2012' instead of 'Jul 2011' to 'Jan 2012' (Fiscal year is 'Jul' to 'Jun'). So if&amp;nbsp; 'Jan' is selected the YTD sum should be for 'Jul 2011' to 'Jan 2012'. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Is there a way to change this set analysis so that the desired result is achieved without having to build a calender in the script?&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Regards &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Danie&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 04 Jan 2012 12:44:07 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/YTD-Set-Analysis/m-p/249497#M94816</guid>
      <dc:creator />
      <dc:date>2012-01-04T12:44:07Z</dc:date>
    </item>
    <item>
      <title>YTD Set Analysis</title>
      <link>https://community.qlik.com/t5/QlikView/YTD-Set-Analysis/m-p/249498#M94817</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt; hei &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;you&amp;nbsp; can set a varaible with this formula&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;vMinDateYTD=if(num(month(vMaxDate))&amp;lt;=6,makedate(max(Year)-1,7,1),makedate(max(Year),7,1));&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;then your set analysis will be&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;sum({&amp;lt;Year,Date={'&amp;gt;=$(vMinDateYTD)&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;lt;=$(vMaxDate)'},Month=,Drawer={'4'}&amp;gt;}JrnAmt).&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 04 Jan 2012 13:34:15 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/YTD-Set-Analysis/m-p/249498#M94817</guid>
      <dc:creator>lironbaram</dc:creator>
      <dc:date>2012-01-04T13:34:15Z</dc:date>
    </item>
  </channel>
</rss>

