<?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 Month over month expression based on selected month in QlikView</title>
    <link>https://community.qlik.com/t5/QlikView/Month-over-month-expression-based-on-selected-month/m-p/808530#M1043515</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;I have copied expression below from someone on the community and it works perfectly for what I am trying to do in comparing month over month page views on a website.&amp;nbsp; However, this expression is using current system month whereas I need the first month to be user selected and then the prior month the one before the month selected.&amp;nbsp; How do I update this expression for that to work?&amp;nbsp; Do I need to create a variable in the load script and if so I am not certain how to do that either.&amp;nbsp; I am new to Qlik Sense so I need some hand holding.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;sum( {$&amp;lt;Month={$(=Month(now()))},Year=&amp;gt;} Pageviews) + &lt;/P&gt;&lt;P&gt;sum({$&amp;lt;Month={$(=Month(AddMonths(now(),-1)))},Year={$(=Year(AddMonths(now(),-1)))}&amp;gt;}Pageviews)&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Mon, 24 Nov 2014 14:47:32 GMT</pubDate>
    <dc:creator />
    <dc:date>2014-11-24T14:47:32Z</dc:date>
    <item>
      <title>Month over month expression based on selected month</title>
      <link>https://community.qlik.com/t5/QlikView/Month-over-month-expression-based-on-selected-month/m-p/808530#M1043515</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;I have copied expression below from someone on the community and it works perfectly for what I am trying to do in comparing month over month page views on a website.&amp;nbsp; However, this expression is using current system month whereas I need the first month to be user selected and then the prior month the one before the month selected.&amp;nbsp; How do I update this expression for that to work?&amp;nbsp; Do I need to create a variable in the load script and if so I am not certain how to do that either.&amp;nbsp; I am new to Qlik Sense so I need some hand holding.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;sum( {$&amp;lt;Month={$(=Month(now()))},Year=&amp;gt;} Pageviews) + &lt;/P&gt;&lt;P&gt;sum({$&amp;lt;Month={$(=Month(AddMonths(now(),-1)))},Year={$(=Year(AddMonths(now(),-1)))}&amp;gt;}Pageviews)&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 24 Nov 2014 14:47:32 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Month-over-month-expression-based-on-selected-month/m-p/808530#M1043515</guid>
      <dc:creator />
      <dc:date>2014-11-24T14:47:32Z</dc:date>
    </item>
    <item>
      <title>Re: Month over month expression based on selected month</title>
      <link>https://community.qlik.com/t5/QlikView/Month-over-month-expression-based-on-selected-month/m-p/808531#M1043516</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;Can you try this&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;sum( {$&amp;lt;Month={$(=Month(now()))},Year=&amp;gt;} Pageviews) + &lt;/P&gt;&lt;P&gt;sum({$&amp;lt;Month={$(=Month(AddMonths(now(),-1)))},Year={$(=Year(now())-1)))}&amp;gt;}Pageviews)&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 24 Nov 2014 14:51:59 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Month-over-month-expression-based-on-selected-month/m-p/808531#M1043516</guid>
      <dc:creator />
      <dc:date>2014-11-24T14:51:59Z</dc:date>
    </item>
    <item>
      <title>Re: Month over month expression based on selected month</title>
      <link>https://community.qlik.com/t5/QlikView/Month-over-month-expression-based-on-selected-month/m-p/808532#M1043517</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;hi&lt;/P&gt;&lt;P&gt;try some thing like below&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;sum({$&amp;lt; Month={$(=max(Month))}, Year=&amp;gt;} Pageviews)+&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;sum({$&amp;lt;Month={$(=max(month)-1)},Year={$(=max(Year)-1)}&amp;gt;}Pageviews)&lt;/STRONG&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 24 Nov 2014 14:57:14 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Month-over-month-expression-based-on-selected-month/m-p/808532#M1043517</guid>
      <dc:creator>sasikanth</dc:creator>
      <dc:date>2014-11-24T14:57:14Z</dc:date>
    </item>
    <item>
      <title>Re: Month over month expression based on selected month</title>
      <link>https://community.qlik.com/t5/QlikView/Month-over-month-expression-based-on-selected-month/m-p/808533#M1043518</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;I tried this and it returns no data.&amp;nbsp; I added a variable to my load script based on another suggestion and alternated the expression.&amp;nbsp; I am still not getting any data however.&amp;nbsp; Please see below.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Expression I am using - &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;sum( {$&amp;lt;Month={$(=vMonth)},Year=&amp;gt;} Pageviews) + &lt;/P&gt;&lt;P&gt;sum({$&amp;lt;Month={$(=Month(AddMonths(vMonth,-1)))},Year={$(=Year(AddMonths(now(),-1)))}&amp;gt;}Pageviews)&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;LOAD SCRIPT - &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;SET ThousandSep=',';&lt;/P&gt;&lt;P&gt;SET DecimalSep='.';&lt;/P&gt;&lt;P&gt;SET MoneyThousandSep=',';&lt;/P&gt;&lt;P&gt;SET MoneyDecimalSep='.';&lt;/P&gt;&lt;P&gt;SET MoneyFormat='$#,##0.00;($#,##0.00)';&lt;/P&gt;&lt;P&gt;SET TimeFormat='h:mm:ss TT';&lt;/P&gt;&lt;P&gt;SET DateFormat='MM/DD/YYYY';&lt;/P&gt;&lt;P&gt;SET TimestampFormat='MM/DD/YYYY';&lt;/P&gt;&lt;P&gt;SET MonthNames='Jan;Feb;Mar;Apr;May;Jun;Jul;Aug;Sep;Oct;Nov;Dec';&lt;/P&gt;&lt;P&gt;SET DayNames='Mon;Tue;Wed;Thu;Fri;Sat;Sun';&lt;/P&gt;&lt;P&gt;SET LongMonthNames='January;February;March;April;May;June;July;August;September;October;November;December';&lt;/P&gt;&lt;P&gt;SET LongDayNames='Monday;Tuesday;Wednesday;Thursday;Friday;Saturday;Sunday';&lt;/P&gt;&lt;P&gt;SET FirstWeekDay=6;&lt;/P&gt;&lt;P&gt;SET BrokenWeeks=1;&lt;/P&gt;&lt;P&gt;SET ReferenceDay=0;&lt;/P&gt;&lt;P&gt;SET FirstMonthOfYear=1;&lt;/P&gt;&lt;P&gt;SET CollationLocale='en-US';&lt;/P&gt;&lt;P&gt;SET vMonth = GetFieldSelections(Month)&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;LOAD&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; Month(Month)as Month,&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; dual('Q' &amp;amp; ceil(Month(Month)/3), &lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; ceil(month(Month)/3)) as Quarter,&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; Year(Month) as Year,&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; "Day Index",&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; Pageviews&lt;/P&gt;&lt;P&gt;FROM [lib://Retainer Client Reports/Monthly Retainer Report_Superior Hire.xlsx]&lt;/P&gt;&lt;P&gt;(ooxml, embedded labels, table is [GA - Behaiv_Site_All2]);&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 24 Nov 2014 20:22:58 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Month-over-month-expression-based-on-selected-month/m-p/808533#M1043518</guid>
      <dc:creator />
      <dc:date>2014-11-24T20:22:58Z</dc:date>
    </item>
    <item>
      <title>Re: Month over month expression based on selected month</title>
      <link>https://community.qlik.com/t5/QlikView/Month-over-month-expression-based-on-selected-month/m-p/808534#M1043519</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;hi,&lt;/P&gt;&lt;P&gt;here what is that Month filed , can you please shown us sample grain ,&lt;/P&gt;&lt;P&gt;if date field is "CREATED_DATE" then&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;LOAD&lt;/P&gt;&lt;P&gt;Month(CREATED_DATE) as Month,&lt;/P&gt;&lt;P&gt;Year(CREATED_DATE) as Year,&lt;/P&gt;&lt;P&gt;.&lt;/P&gt;&lt;P&gt;.&lt;/P&gt;&lt;P&gt;.&lt;/P&gt;&lt;P&gt;FROM ......................;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;then use both these fileds Month &amp;amp; Year&lt;/P&gt;&lt;P&gt;in the above expression&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;sum({$&amp;lt; Month={$(=max(Month))}, Year=&amp;gt;} Pageviews)+&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;sum({$&amp;lt;Month={$(=max(month)-1)},Year={$(=max(Year)-1)}&amp;gt;}Pageviews)&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Here the expressoin take selected month only&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thaks&lt;/P&gt;&lt;P&gt;Sasi&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 25 Nov 2014 04:20:20 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Month-over-month-expression-based-on-selected-month/m-p/808534#M1043519</guid>
      <dc:creator>sasikanth</dc:creator>
      <dc:date>2014-11-25T04:20:20Z</dc:date>
    </item>
  </channel>
</rss>

