<?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: How to Get Prev Month Value in QlikView</title>
    <link>https://community.qlik.com/t5/QlikView/How-to-Get-Prev-Month-Value/m-p/855808#M299961</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Can you share your sample with us? It will be easier to understand your structure and give you recommendations.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Best,&lt;/P&gt;&lt;P&gt;Sunny&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Tue, 09 Jun 2015 12:20:45 GMT</pubDate>
    <dc:creator>sunny_talwar</dc:creator>
    <dc:date>2015-06-09T12:20:45Z</dc:date>
    <item>
      <title>How to Get Prev Month Value</title>
      <link>https://community.qlik.com/t5/QlikView/How-to-Get-Prev-Month-Value/m-p/855802#M299955</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi All,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I need to get Previous Month Value when i make a selection, but struggling to get it right?&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;E.g if i select May on a list box it must show me values for April.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;like -1&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;i Tried:&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;=sum({&amp;lt;Dates={'&amp;gt;=$(=only(Dates)-2)&amp;lt;=$(=only(Dates))'}&amp;gt;}Sales)&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;and&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;=sum( {$&amp;lt;Year = {$(=Only(Year)-1)}&amp;gt;} Sales )&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;im i missing something in here?&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Regards:&lt;/P&gt;&lt;P&gt;Thabiso&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 09 Jun 2015 12:06:15 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/How-to-Get-Prev-Month-Value/m-p/855802#M299955</guid>
      <dc:creator />
      <dc:date>2015-06-09T12:06:15Z</dc:date>
    </item>
    <item>
      <title>Re: How to Get Prev Month Value</title>
      <link>https://community.qlik.com/t5/QlikView/How-to-Get-Prev-Month-Value/m-p/855803#M299956</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;try like this:&lt;/P&gt;&lt;P&gt;&lt;SPAN style="color: #000000; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; font-size: 13px;"&gt;sum({&amp;lt;Month_Name={'&amp;gt;=$(monthname(monthname(date)-1)'}&amp;gt;}Sales)&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="color: #000000; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; font-size: 13px;"&gt;&lt;BR /&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="color: #000000; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; font-size: 13px;"&gt;and &lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="color: #000000; font-size: 13px; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif;"&gt;=sum( {$&amp;lt;Year = {"$(=(Year-1)"}&amp;gt;} Sales )&lt;/SPAN&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 09 Jun 2015 12:10:50 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/How-to-Get-Prev-Month-Value/m-p/855803#M299956</guid>
      <dc:creator>avinashelite</dc:creator>
      <dc:date>2015-06-09T12:10:50Z</dc:date>
    </item>
    <item>
      <title>Re: How to Get Prev Month Value</title>
      <link>https://community.qlik.com/t5/QlikView/How-to-Get-Prev-Month-Value/m-p/855804#M299957</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 do you mean in Month_Name? and what should i use as a Dimension?&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 09 Jun 2015 12:14:08 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/How-to-Get-Prev-Month-Value/m-p/855804#M299957</guid>
      <dc:creator />
      <dc:date>2015-06-09T12:14:08Z</dc:date>
    </item>
    <item>
      <title>Re: How to Get Prev Month Value</title>
      <link>https://community.qlik.com/t5/QlikView/How-to-Get-Prev-Month-Value/m-p/855805#M299958</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Are you trying to do this on a chart where Month is your dimension? If yes than you will have to use Above() function. If not then this should work:&lt;/P&gt;&lt;P&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;STRONG&gt;=Sum({&amp;lt;Dates={"&amp;gt;=$(=Date(AddMonths(Max(Dates), -1), 'DatesFieldFormat')) &amp;lt;= $(=Date(Max(Dates)))"}&amp;gt;} Sales) &lt;/STRONG&gt;&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;BR /&gt;&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;/P&gt;&lt;P&gt;&lt;STRONG style="color: #3d3d3d; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; font-size: 13px;"&gt;=Sum({&amp;lt;Dates={"$(='&amp;gt;=' &amp;amp; Date(AddMonths(Max(Dates), -1), 'DatesFieldFormat') &amp;amp; '&amp;lt;=' &amp;amp; Date(Max(Dates)))"}&amp;gt;} Sales)&lt;/STRONG&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 09 Jun 2015 12:15:39 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/How-to-Get-Prev-Month-Value/m-p/855805#M299958</guid>
      <dc:creator>sunny_talwar</dc:creator>
      <dc:date>2015-06-09T12:15:39Z</dc:date>
    </item>
    <item>
      <title>Re: How to Get Prev Month Value</title>
      <link>https://community.qlik.com/t5/QlikView/How-to-Get-Prev-Month-Value/m-p/855806#M299959</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;That is why it is better to post sample app, to understand better by the community members. no offence.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 09 Jun 2015 12:16:24 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/How-to-Get-Prev-Month-Value/m-p/855806#M299959</guid>
      <dc:creator>qlikmsg4u</dc:creator>
      <dc:date>2015-06-09T12:16:24Z</dc:date>
    </item>
    <item>
      <title>Re: How to Get Prev Month Value</title>
      <link>https://community.qlik.com/t5/QlikView/How-to-Get-Prev-Month-Value/m-p/855807#M299960</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi All,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;i want to use it on a Straight Table, so i just need sample Test so that i can Apply it on my Large Data Set, i created a Sample Model.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Regards.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 09 Jun 2015 12:18:31 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/How-to-Get-Prev-Month-Value/m-p/855807#M299960</guid>
      <dc:creator />
      <dc:date>2015-06-09T12:18:31Z</dc:date>
    </item>
    <item>
      <title>Re: How to Get Prev Month Value</title>
      <link>https://community.qlik.com/t5/QlikView/How-to-Get-Prev-Month-Value/m-p/855808#M299961</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Can you share your sample with us? It will be easier to understand your structure and give you recommendations.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Best,&lt;/P&gt;&lt;P&gt;Sunny&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 09 Jun 2015 12:20:45 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/How-to-Get-Prev-Month-Value/m-p/855808#M299961</guid>
      <dc:creator>sunny_talwar</dc:creator>
      <dc:date>2015-06-09T12:20:45Z</dc:date>
    </item>
    <item>
      <title>Re: How to Get Prev Month Value</title>
      <link>https://community.qlik.com/t5/QlikView/How-to-Get-Prev-Month-Value/m-p/855809#M299962</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Do you just want the value for april when you select april?&lt;/P&gt;&lt;P&gt;Then it is: &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;sum({$&amp;lt;Year,Month,Date={"&amp;gt;=$(=MonthStart(Min(Date),-1))&amp;lt;=$(=MonthEnd(Min(Date),-1))"}&amp;gt;} SalesAmount)&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;If you want to show the value for april next to may in a seperate column like this:&lt;/P&gt;&lt;P&gt;Month&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; Sales&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; Sales Last Month&lt;/P&gt;&lt;P&gt;April&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/P&gt;&lt;P&gt;May&lt;/P&gt;&lt;P&gt;Jun&lt;/P&gt;&lt;P&gt;Then i suggest that you take a look at this post, where I do somethng similar:&lt;/P&gt;&lt;P&gt;&lt;A href="https://community.qlik.com/message/785734"&gt;Re: Last Year  and Current Year Sales in Current Year Only&lt;/A&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;//Martin&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 09 Jun 2015 12:22:52 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/How-to-Get-Prev-Month-Value/m-p/855809#M299962</guid>
      <dc:creator>martin_dideriks</dc:creator>
      <dc:date>2015-06-09T12:22:52Z</dc:date>
    </item>
    <item>
      <title>Re: How to Get Prev Month Value</title>
      <link>https://community.qlik.com/t5/QlikView/How-to-Get-Prev-Month-Value/m-p/855810#M299963</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;&lt;STRONG&gt;Sample Data:&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;TABLE border="1" class="jiveBorder" style="border: 1px solid rgb(0, 0, 0); width: 100%;"&gt;&lt;TBODY&gt;&lt;TR&gt;&lt;TH style="text-align: center; background-color: #6690bc; color: #ffffff; padding: 2px;" valign="middle"&gt;&lt;STRONG&gt;Day&lt;/STRONG&gt;&lt;/TH&gt;&lt;TH style="text-align: center; background-color: #6690bc; color: #ffffff; padding: 2px;" valign="middle"&gt;&lt;STRONG&gt;MonthDate&lt;/STRONG&gt;&lt;/TH&gt;&lt;TH style="text-align: center; background-color: #6690bc; color: #ffffff; padding: 2px;" valign="middle"&gt;&lt;STRONG&gt;Dates&lt;/STRONG&gt;&lt;/TH&gt;&lt;TH style="text-align: center; background-color: #6690bc; color: #ffffff; padding: 2px;" valign="middle"&gt;&lt;STRONG&gt;Year&lt;/STRONG&gt;&lt;/TH&gt;&lt;TH style="text-align: center; background-color: #6690bc; color: #ffffff; padding: 2px;" valign="middle"&gt;&lt;STRONG&gt;Sales&lt;/STRONG&gt;&lt;/TH&gt;&lt;/TR&gt;&lt;TR&gt;&lt;TD style="padding: 2px;"&gt;10&lt;/TD&gt;&lt;TD style="padding: 2px;"&gt;Jan&lt;/TD&gt;&lt;TD style="padding: 2px;"&gt;2015-01-10&lt;/TD&gt;&lt;TD style="padding: 2px;"&gt;2015&lt;/TD&gt;&lt;TD style="padding: 2px;"&gt;100&lt;/TD&gt;&lt;/TR&gt;&lt;TR&gt;&lt;TD style="padding: 2px;"&gt;24&lt;/TD&gt;&lt;TD style="padding: 2px;"&gt;Feb&lt;/TD&gt;&lt;TD style="padding: 2px;"&gt;2015-02-24&lt;/TD&gt;&lt;TD style="padding: 2px;"&gt;2015&lt;/TD&gt;&lt;TD style="padding: 2px;"&gt;23&lt;/TD&gt;&lt;/TR&gt;&lt;TR&gt;&lt;TD style="padding: 2px;"&gt;24&lt;/TD&gt;&lt;TD style="padding: 2px;"&gt;Mar&lt;/TD&gt;&lt;TD style="padding: 2px;"&gt;2015-03-24&lt;/TD&gt;&lt;TD style="padding: 2px;"&gt;2015&lt;/TD&gt;&lt;TD style="padding: 2px;"&gt;45&lt;/TD&gt;&lt;/TR&gt;&lt;TR&gt;&lt;TD&gt;10&lt;/TD&gt;&lt;TD&gt;May&lt;/TD&gt;&lt;TD&gt;2015-05-10&lt;/TD&gt;&lt;TD&gt;2015&lt;/TD&gt;&lt;TD&gt;345&lt;/TD&gt;&lt;/TR&gt;&lt;/TBODY&gt;&lt;/TABLE&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;Listbox:&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;MonthDate:&lt;/P&gt;&lt;P&gt;Jan&lt;/P&gt;&lt;P&gt;Feb&lt;/P&gt;&lt;P&gt;Mar&lt;/P&gt;&lt;P&gt;Apr&lt;/P&gt;&lt;P&gt;May&lt;/P&gt;&lt;P&gt;Jun&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;So if i select Mar it must show me values for Feb.....and if i select Feb it must show values for Jan.....and so on&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Hope this will help&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thanks&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 09 Jun 2015 12:26:28 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/How-to-Get-Prev-Month-Value/m-p/855810#M299963</guid>
      <dc:creator />
      <dc:date>2015-06-09T12:26:28Z</dc:date>
    </item>
    <item>
      <title>Re: How to Get Prev Month Value</title>
      <link>https://community.qlik.com/t5/QlikView/How-to-Get-Prev-Month-Value/m-p/855811#M299964</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;Basically it has to calculate for Previous Month&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;e.g if i press Jun, it must give me sales for May&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thanks.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 09 Jun 2015 12:35:35 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/How-to-Get-Prev-Month-Value/m-p/855811#M299964</guid>
      <dc:creator />
      <dc:date>2015-06-09T12:35:35Z</dc:date>
    </item>
    <item>
      <title>Re: How to Get Prev Month Value</title>
      <link>https://community.qlik.com/t5/QlikView/How-to-Get-Prev-Month-Value/m-p/855812#M299965</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi SunIndia, yours it gives me current month Selected thou i need Previous month from that selected Month.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;if on my listbox i select March, it must calculate for February.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thanks&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 09 Jun 2015 12:37:33 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/How-to-Get-Prev-Month-Value/m-p/855812#M299965</guid>
      <dc:creator />
      <dc:date>2015-06-09T12:37:33Z</dc:date>
    </item>
    <item>
      <title>Re: How to Get Prev Month Value</title>
      <link>https://community.qlik.com/t5/QlikView/How-to-Get-Prev-Month-Value/m-p/855813#M299966</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Try this expression:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;=Sum({&amp;lt;Dates = {"$(='&amp;gt;=' &amp;amp; Date(AddMonths(MonthStart(Max(Dates)), -1), 'YYYY-MM-DD') &amp;amp; '&amp;lt;=' &amp;amp; Date(MonthEnd(Max(Dates)), 'YYYY-MM-DD'))"}, MonthDate = &amp;gt;}Sales)&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;IMG alt="Capture.PNG" class="jive-image image-1" src="https://community.qlik.com/legacyfs/online/88795_Capture.PNG" style="height: auto;" /&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Attaching the qvw for your review purposes.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Best,&lt;/P&gt;&lt;P&gt;Sunny&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 09 Jun 2015 12:39:45 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/How-to-Get-Prev-Month-Value/m-p/855813#M299966</guid>
      <dc:creator>sunny_talwar</dc:creator>
      <dc:date>2015-06-09T12:39:45Z</dc:date>
    </item>
  </channel>
</rss>

