<?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: Creating Last 6/12/18/24 Months in QlikView</title>
    <link>https://community.qlik.com/t5/QlikView/Creating-Last-6-12-18-24-Months/m-p/614783#M682223</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;&lt;SPAN style="font-size: 8pt;"&gt;if I understand &lt;BR /&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 8pt;"&gt;you can add some flag in a tabel associated to your date &lt;BR /&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 8pt;"&gt;LET Start = num(makedate(2012,1,1));&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 8pt;"&gt;LET End = num(makedate(2014,12,1));&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 8pt;"&gt;LET NumOfDays = End - Start + 1;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 8pt; line-height: 1.5em;"&gt;&lt;BR /&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 8pt; line-height: 1.5em;"&gt;Date_src:&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 8pt;"&gt;LOAD&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 8pt;"&gt;$(Start) + Rowno() -1 as DateId&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 8pt;"&gt;AUTOGENERATE $(NumOfDays);&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 8pt;"&gt;ClaimCloseDateFlag:&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 8pt;"&gt;LOAD&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 8pt;"&gt;DateId as &lt;SPAN style="color: #3d3d3d; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; font-size: 12.727272033691406px;"&gt; [Claim Close Date]&lt;/SPAN&gt;,&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 8pt;"&gt;&lt;STRONG&gt;if(DateId &amp;gt;= AddMonths(MonthStart(today()), -6) and DateId &amp;lt;= monthstart(today())-1, 1, 0) as Flag6Month&lt;/STRONG&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 8pt;"&gt;&lt;STRONG&gt;// similar for Flag12,,,,,,,18.....2$&lt;/STRONG&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 8pt;"&gt;RESIDENT Date_src;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 8pt;"&gt;Drop Table Date_src;&lt;/SPAN&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Tue, 08 Apr 2014 16:45:14 GMT</pubDate>
    <dc:creator>maxgro</dc:creator>
    <dc:date>2014-04-08T16:45:14Z</dc:date>
    <item>
      <title>Creating Last 6/12/18/24 Months</title>
      <link>https://community.qlik.com/t5/QlikView/Creating-Last-6-12-18-24-Months/m-p/614781#M682218</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Guys,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I have this field [Claim Close Date] that is my date field, set day-by-day. I want to create a field that gets the last 6 months, for example: we are in april/2014, i want to get all days from october/2013 - march/2014 ; I want that for last 12 months (march/2013 ~ march/2014), and I want the same for the last 18 months and the last 24 months.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Can you guys script for me a way out of that?&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 08 Apr 2014 14:09:30 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Creating-Last-6-12-18-24-Months/m-p/614781#M682218</guid>
      <dc:creator />
      <dc:date>2014-04-08T14:09:30Z</dc:date>
    </item>
    <item>
      <title>Re: Creating Last 6/12/18/24 Months</title>
      <link>https://community.qlik.com/t5/QlikView/Creating-Last-6-12-18-24-Months/m-p/614782#M682221</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;I think you have to create two fields : start date and end date.&lt;BR /&gt;Then, you have to use the interval match function&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 08 Apr 2014 14:14:45 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Creating-Last-6-12-18-24-Months/m-p/614782#M682221</guid>
      <dc:creator>yduval75</dc:creator>
      <dc:date>2014-04-08T14:14:45Z</dc:date>
    </item>
    <item>
      <title>Re: Creating Last 6/12/18/24 Months</title>
      <link>https://community.qlik.com/t5/QlikView/Creating-Last-6-12-18-24-Months/m-p/614783#M682223</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;&lt;SPAN style="font-size: 8pt;"&gt;if I understand &lt;BR /&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 8pt;"&gt;you can add some flag in a tabel associated to your date &lt;BR /&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 8pt;"&gt;LET Start = num(makedate(2012,1,1));&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 8pt;"&gt;LET End = num(makedate(2014,12,1));&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 8pt;"&gt;LET NumOfDays = End - Start + 1;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 8pt; line-height: 1.5em;"&gt;&lt;BR /&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 8pt; line-height: 1.5em;"&gt;Date_src:&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 8pt;"&gt;LOAD&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 8pt;"&gt;$(Start) + Rowno() -1 as DateId&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 8pt;"&gt;AUTOGENERATE $(NumOfDays);&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 8pt;"&gt;ClaimCloseDateFlag:&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 8pt;"&gt;LOAD&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 8pt;"&gt;DateId as &lt;SPAN style="color: #3d3d3d; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; font-size: 12.727272033691406px;"&gt; [Claim Close Date]&lt;/SPAN&gt;,&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 8pt;"&gt;&lt;STRONG&gt;if(DateId &amp;gt;= AddMonths(MonthStart(today()), -6) and DateId &amp;lt;= monthstart(today())-1, 1, 0) as Flag6Month&lt;/STRONG&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 8pt;"&gt;&lt;STRONG&gt;// similar for Flag12,,,,,,,18.....2$&lt;/STRONG&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 8pt;"&gt;RESIDENT Date_src;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 8pt;"&gt;Drop Table Date_src;&lt;/SPAN&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 08 Apr 2014 16:45:14 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Creating-Last-6-12-18-24-Months/m-p/614783#M682223</guid>
      <dc:creator>maxgro</dc:creator>
      <dc:date>2014-04-08T16:45:14Z</dc:date>
    </item>
    <item>
      <title>Re: Creating Last 6/12/18/24 Months</title>
      <link>https://community.qlik.com/t5/QlikView/Creating-Last-6-12-18-24-Months/m-p/614784#M682225</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;This works just perfect, thank you. We use alot the numbers from last 6 months and 12 months. Thank you very much!&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 08 Apr 2014 17:45:30 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Creating-Last-6-12-18-24-Months/m-p/614784#M682225</guid>
      <dc:creator />
      <dc:date>2014-04-08T17:45:30Z</dc:date>
    </item>
  </channel>
</rss>

