<?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: Last 6 months as a dimension in QlikView</title>
    <link>https://community.qlik.com/t5/QlikView/Last-6-months-as-a-dimension/m-p/808560#M285421</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;It is fine to restrict on the expression level.&amp;nbsp; I prefer calculated dimension for one reason only - if there are multiple expressions, there is no need to make this change in every one if you use calculated dimension.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Mon, 30 Mar 2015 12:54:58 GMT</pubDate>
    <dc:creator>Anonymous</dc:creator>
    <dc:date>2015-03-30T12:54:58Z</dc:date>
    <item>
      <title>Last 6 months as a dimension</title>
      <link>https://community.qlik.com/t5/QlikView/Last-6-months-as-a-dimension/m-p/808554#M285415</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 a table with 18 months data. However, in pivot I need only last 6 months as a dimension. Any suggestions?&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 27 Mar 2015 15:30:19 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Last-6-months-as-a-dimension/m-p/808554#M285415</guid>
      <dc:creator />
      <dc:date>2015-03-27T15:30:19Z</dc:date>
    </item>
    <item>
      <title>Re: Last 6 months as a dimension</title>
      <link>https://community.qlik.com/t5/QlikView/Last-6-months-as-a-dimension/m-p/808555#M285416</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Best choice is to create a dimension Last6Mos in the script, for example, you have table Calendar containing Date and MonthYr fields among others.&amp;nbsp; In this case:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;LEFT JOIN (Calendar) LOAD&lt;BR /&gt; MonthYr,&lt;BR /&gt; MonthYr as Last6Mos&lt;BR /&gt;RESIDENT Calendar&lt;BR /&gt;WHERE Date &amp;gt;= monthstart(today(),-6);&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;If you don't want to change the script, use calculated dimension in your chart:&lt;/P&gt;&lt;P&gt;aggr(only({&amp;lt;Date={"&amp;gt;=date(monthstart(today(),-6))"}&amp;gt;} MonthYr),MonthYr)&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 27 Mar 2015 16:04:53 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Last-6-months-as-a-dimension/m-p/808555#M285416</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2015-03-27T16:04:53Z</dc:date>
    </item>
    <item>
      <title>Re: Last 6 months as a dimension</title>
      <link>https://community.qlik.com/t5/QlikView/Last-6-months-as-a-dimension/m-p/808556#M285417</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Not that beautiful but it works:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;=If(Year(AddMonths(vDate, -6)) = Year(vDate),&lt;/P&gt;&lt;P&gt;If(Month &amp;gt; Month(AddMonths(vDate, -6)) and Month &amp;lt;= Month(vDate), Month),&lt;/P&gt;&lt;P&gt;If(Month &amp;gt; Month(AddMonths(vDate, -6)) or Month &amp;lt;= Month(vDate), Month))&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;where vDate could be your Today()&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Best regards,&lt;/P&gt;&lt;P&gt;Patrick&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 27 Mar 2015 16:21:46 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Last-6-months-as-a-dimension/m-p/808556#M285417</guid>
      <dc:creator>patroser</dc:creator>
      <dc:date>2015-03-27T16:21:46Z</dc:date>
    </item>
    <item>
      <title>Re: Last 6 months as a dimension</title>
      <link>https://community.qlik.com/t5/QlikView/Last-6-months-as-a-dimension/m-p/808557#M285418</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi, Michael,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I need this in pivot only, so I cant change th scipt. However, the formula&amp;nbsp; that u wrote isn't working &lt;IMG src="https://community.qlik.com/legacyfs/online/emoticons/sad.png" /&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 30 Mar 2015 11:11:17 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Last-6-months-as-a-dimension/m-p/808557#M285418</guid>
      <dc:creator />
      <dc:date>2015-03-30T11:11:17Z</dc:date>
    </item>
    <item>
      <title>Re: Last 6 months as a dimension</title>
      <link>https://community.qlik.com/t5/QlikView/Last-6-months-as-a-dimension/m-p/808558#M285419</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi Diana,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Still, the best option is to have an &lt;STRONG&gt;additional&lt;/STRONG&gt; field for this.&amp;nbsp; Not &lt;STRONG&gt;instead&lt;/STRONG&gt; of the current Month field.&amp;nbsp; So you can use new field in one chart and old field in another.&lt;/P&gt;&lt;P&gt;As for the "isn't working" - my example is a "generic" one, I don't know the specific names in your application nor you data model.&amp;nbsp; I can be more specific if you upload your application.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 30 Mar 2015 12:40:11 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Last-6-months-as-a-dimension/m-p/808558#M285419</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2015-03-30T12:40:11Z</dc:date>
    </item>
    <item>
      <title>Re: Last 6 months as a dimension</title>
      <link>https://community.qlik.com/t5/QlikView/Last-6-months-as-a-dimension/m-p/808559#M285420</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;What if instead of creating new field,&lt;/P&gt;&lt;P&gt;If i took Month as dimension and&lt;/P&gt;&lt;P&gt;in Expression if i restrict data for latest 6 month only&lt;/P&gt;&lt;P&gt;like Sum({&amp;lt;Month={"&amp;gt;=$(=Month(AddMonths(max(Month),6)))&amp;lt;=$(=Month(max(Month)))"}&amp;gt;}Sales)&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Regards&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 30 Mar 2015 12:47:26 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Last-6-months-as-a-dimension/m-p/808559#M285420</guid>
      <dc:creator>PrashantSangle</dc:creator>
      <dc:date>2015-03-30T12:47:26Z</dc:date>
    </item>
    <item>
      <title>Re: Last 6 months as a dimension</title>
      <link>https://community.qlik.com/t5/QlikView/Last-6-months-as-a-dimension/m-p/808560#M285421</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;It is fine to restrict on the expression level.&amp;nbsp; I prefer calculated dimension for one reason only - if there are multiple expressions, there is no need to make this change in every one if you use calculated dimension.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 30 Mar 2015 12:54:58 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Last-6-months-as-a-dimension/m-p/808560#M285421</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2015-03-30T12:54:58Z</dc:date>
    </item>
    <item>
      <title>Re: Last 6 months as a dimension</title>
      <link>https://community.qlik.com/t5/QlikView/Last-6-months-as-a-dimension/m-p/808561#M285422</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi Diana,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;you can do it in two ways,&lt;/P&gt;&lt;P&gt;1.In the dimension add a calculate dimension using the if condition:&lt;/P&gt;&lt;P&gt;&lt;SPAN style="color: #3d3d3d; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; font-size: 13px;"&gt;If(Month &amp;lt;= monthname(today()) and Month&amp;gt;=mothname(date_feild)-18, dimension_you_want)&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="color: #3d3d3d; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; font-size: 13px;"&gt;or &lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="color: #3d3d3d; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; font-size: 13px;"&gt;2.using the set analysis:&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="color: #3d3d3d; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; font-size: 13px;"&gt;&lt;SPAN style="font-size: 10.0pt; font-family: 'Calibri',sans-serif; color: blue;"&gt;sum&lt;/SPAN&gt;&lt;SPAN style="font-size: 10.0pt; font-family: 'Calibri',sans-serif; color: black;"&gt;({&amp;lt;&lt;/SPAN&gt;&lt;SPAN style="font-size: 10.0pt; font-family: 'Calibri',sans-serif; color: maroon;"&gt;Calender_Date&lt;/SPAN&gt;&lt;SPAN style="font-size: 10.0pt; font-family: 'Calibri',sans-serif; color: black;"&gt;={&lt;/SPAN&gt;&lt;SPAN style="font-size: 10.0pt; font-family: 'Calibri',sans-serif; color: maroon;"&gt;"&amp;gt;=$(&lt;SPAN style="color: #3d3d3d; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; font-size: 13px;"&gt;Month &amp;lt;= monthname(today()) and Month&amp;gt;=mothname(date_feild))-18&lt;/SPAN&gt;))"&lt;/SPAN&gt;&lt;SPAN style="font-size: 10.0pt; font-family: 'Calibri',sans-serif; color: black;"&gt;}&amp;gt;}&lt;/SPAN&gt;&lt;SPAN style="font-size: 10.0pt; font-family: 'Calibri',sans-serif; color: maroon;"&gt;sales&lt;/SPAN&gt;&lt;SPAN style="font-size: 10.0pt; font-family: 'Calibri',sans-serif; color: black;"&gt;) &lt;/SPAN&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 30 Mar 2015 12:57:49 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Last-6-months-as-a-dimension/m-p/808561#M285422</guid>
      <dc:creator>avinashelite</dc:creator>
      <dc:date>2015-03-30T12:57:49Z</dc:date>
    </item>
    <item>
      <title>Re: Last 6 months as a dimension</title>
      <link>https://community.qlik.com/t5/QlikView/Last-6-months-as-a-dimension/m-p/808562#M285423</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Ok, Thanks for clearification.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;It was just my doubt.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Regards&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 30 Mar 2015 13:12:41 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Last-6-months-as-a-dimension/m-p/808562#M285423</guid>
      <dc:creator>PrashantSangle</dc:creator>
      <dc:date>2015-03-30T13:12:41Z</dc:date>
    </item>
  </channel>
</rss>

