<?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: Pivot Table - Avg last 5 days in QlikView</title>
    <link>https://community.qlik.com/t5/QlikView/Pivot-Table-Avg-last-5-days/m-p/1069410#M357298</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;I replaced with my Format ('DD.MM.YYYY') but nothing showing up, now I have attached a sample application and used the expression suggested by sureshqv, but nothing....&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Fri, 19 Feb 2016 11:13:28 GMT</pubDate>
    <dc:creator>pamaxeed</dc:creator>
    <dc:date>2016-02-19T11:13:28Z</dc:date>
    <item>
      <title>Pivot Table - Avg last 5 days</title>
      <link>https://community.qlik.com/t5/QlikView/Pivot-Table-Avg-last-5-days/m-p/1069403#M357291</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 a question regarding the following calculation.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I have a pivot table with Account and Date as dimension:&lt;/P&gt;&lt;P&gt;&lt;IMG __jive_id="115224" alt="Capture.PNG" class="jive-image image-1" src="https://community.qlik.com/legacyfs/online/115224_Capture.PNG" style="height: 214px; width: 620px;" /&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;How is it possible to get the AVG Amount of the last 5 days for every single date dimension value?&lt;/P&gt;&lt;P&gt;I am struggling I have tried with Set Analysis but I could not come to a solution&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;avg({&amp;lt;[Ref Date]={"&amp;lt;=$(=Max([Ref Date]))&amp;gt;=$(=Only([Ref Date]-5)"}&amp;gt;} AMOUNT_BU)&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Anyone can help me?&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Update:&lt;/P&gt;&lt;P&gt;I have a&lt;/P&gt;&lt;P&gt;dded a sample application, the result in the Avg Last 5 Days is not correct!&lt;/P&gt;&lt;P&gt;The expression I used here is:&lt;/P&gt;&lt;P&gt;avg({&amp;lt;[Date]={'&amp;gt;=$(=Date(Max([Date])-5))&amp;lt;=$(=Date(Max([Date])))'}&amp;gt;} Amount)&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Kind regars,&lt;/P&gt;&lt;P&gt;Patric&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Nachricht geändert durch Patric Amatulli&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 19 Feb 2016 10:50:14 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Pivot-Table-Avg-last-5-days/m-p/1069403#M357291</guid>
      <dc:creator>pamaxeed</dc:creator>
      <dc:date>2016-02-19T10:50:14Z</dc:date>
    </item>
    <item>
      <title>Re: Pivot Table - Avg last 5 days</title>
      <link>https://community.qlik.com/t5/QlikView/Pivot-Table-Avg-last-5-days/m-p/1069404#M357292</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;avg({&amp;lt;&lt;SPAN style="color: #3d3d3d; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; font-size: 12px;"&gt;[Ref Date]&lt;/SPAN&gt; ={"$(='&amp;gt;=' &amp;amp; Date(vDay-7) &amp;amp; '&amp;lt;=' &amp;amp; Date(vDay))"}&amp;gt;} &lt;SPAN style="color: #3d3d3d; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; font-size: 12px;"&gt;AMOUNT_BU&lt;/SPAN&gt;)&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P style="font-size: 12px; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; color: #3d3d3d;"&gt;avg({&amp;lt;[Ref Date]={"&amp;lt;=$(=Max([Ref Date]))&amp;gt;=$(=Only([Ref Date]-5)"}&amp;gt;} AMOUNT_BU)&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 19 Feb 2016 10:53:39 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Pivot-Table-Avg-last-5-days/m-p/1069404#M357292</guid>
      <dc:creator>Chanty4u</dc:creator>
      <dc:date>2016-02-19T10:53:39Z</dc:date>
    </item>
    <item>
      <title>Re: Pivot Table - Avg last 5 days</title>
      <link>https://community.qlik.com/t5/QlikView/Pivot-Table-Avg-last-5-days/m-p/1069405#M357293</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Can you explain what you did?&lt;/P&gt;&lt;P&gt;What is behind the vDay variable?&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 19 Feb 2016 10:55:17 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Pivot-Table-Avg-last-5-days/m-p/1069405#M357293</guid>
      <dc:creator>pamaxeed</dc:creator>
      <dc:date>2016-02-19T10:55:17Z</dc:date>
    </item>
    <item>
      <title>Re: Pivot Table - Avg last 5 days</title>
      <link>https://community.qlik.com/t5/QlikView/Pivot-Table-Avg-last-5-days/m-p/1069406#M357294</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;I think you need to Add Date() function to match the formatting of Ref Date with your filter:&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;Avg({&amp;lt;[Ref Date]={"&lt;SPAN style="color: #3d3d3d; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; font-size: 13px;"&gt;&amp;gt;=$(=Date(Max([Ref Date])-5, '&lt;/SPAN&gt;&lt;SPAN style="color: #3d3d3d; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; font-size: 13px;"&gt;YourRefDateFieldFormatHere&lt;/SPAN&gt;&lt;SPAN style="color: #3d3d3d; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; font-size: 13px;"&gt;'))&lt;/SPAN&gt;&amp;lt;=$(=Date(Max([Ref Date]), 'YourRefDateFieldFormatHere'))"}&amp;gt;} AMOUNT_BU)&lt;/STRONG&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 19 Feb 2016 10:55:18 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Pivot-Table-Avg-last-5-days/m-p/1069406#M357294</guid>
      <dc:creator>sunny_talwar</dc:creator>
      <dc:date>2016-02-19T10:55:18Z</dc:date>
    </item>
    <item>
      <title>Re: Pivot Table - Avg last 5 days</title>
      <link>https://community.qlik.com/t5/QlikView/Pivot-Table-Avg-last-5-days/m-p/1069407#M357295</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Is not shown up anything...&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 19 Feb 2016 11:02:24 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Pivot-Table-Avg-last-5-days/m-p/1069407#M357295</guid>
      <dc:creator>pamaxeed</dc:creator>
      <dc:date>2016-02-19T11:02:24Z</dc:date>
    </item>
    <item>
      <title>Re: Pivot Table - Avg last 5 days</title>
      <link>https://community.qlik.com/t5/QlikView/Pivot-Table-Avg-last-5-days/m-p/1069408#M357296</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;&lt;SPAN style="color: #3d3d3d; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; font-size: 13px;"&gt;sry try dis&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;avg({&amp;lt;&lt;SPAN style="color: #3d3d3d; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; font-size: 12px; background-color: #f2f2f2;"&gt;[Ref Date]&lt;/SPAN&gt;={‘&amp;gt;=$(=Date(Max(&lt;SPAN style="color: #3d3d3d; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; font-size: 12px; background-color: #f2f2f2;"&gt;[Ref Date]&lt;/SPAN&gt;)-5))&amp;lt;=$(=Date(Max(&lt;SPAN style="color: #3d3d3d; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; font-size: 12px; background-color: #f2f2f2;"&gt;[Ref Date]&lt;/SPAN&gt;)))’}&amp;gt;} &lt;SPAN style="color: #3d3d3d; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; font-size: 12px; background-color: #f2f2f2;"&gt;AMOUNT_BU&lt;/SPAN&gt;)&lt;/SPAN&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 19 Feb 2016 11:04:45 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Pivot-Table-Avg-last-5-days/m-p/1069408#M357296</guid>
      <dc:creator>Chanty4u</dc:creator>
      <dc:date>2016-02-19T11:04:45Z</dc:date>
    </item>
    <item>
      <title>Re: Pivot Table - Avg last 5 days</title>
      <link>https://community.qlik.com/t5/QlikView/Pivot-Table-Avg-last-5-days/m-p/1069409#M357297</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Did you replace &lt;STRONG style="color: #3d3d3d; font-size: 13px; font-style: inherit; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; font-weight: inherit;"&gt;YourRefDateFieldFormatHere&lt;STRONG&gt; &lt;/STRONG&gt;&lt;/STRONG&gt;&lt;SPAN style="font-weight: inherit; font-style: inherit;"&gt;with your date field format or did you just copy paste my expression?&lt;/SPAN&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 19 Feb 2016 11:08:15 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Pivot-Table-Avg-last-5-days/m-p/1069409#M357297</guid>
      <dc:creator>sunny_talwar</dc:creator>
      <dc:date>2016-02-19T11:08:15Z</dc:date>
    </item>
    <item>
      <title>Re: Pivot Table - Avg last 5 days</title>
      <link>https://community.qlik.com/t5/QlikView/Pivot-Table-Avg-last-5-days/m-p/1069410#M357298</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;I replaced with my Format ('DD.MM.YYYY') but nothing showing up, now I have attached a sample application and used the expression suggested by sureshqv, but nothing....&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 19 Feb 2016 11:13:28 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Pivot-Table-Avg-last-5-days/m-p/1069410#M357298</guid>
      <dc:creator>pamaxeed</dc:creator>
      <dc:date>2016-02-19T11:13:28Z</dc:date>
    </item>
    <item>
      <title>Re: Pivot Table - Avg last 5 days</title>
      <link>https://community.qlik.com/t5/QlikView/Pivot-Table-Avg-last-5-days/m-p/1069411#M357299</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Check my attached sample application...&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 19 Feb 2016 11:20:04 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Pivot-Table-Avg-last-5-days/m-p/1069411#M357299</guid>
      <dc:creator>pamaxeed</dc:creator>
      <dc:date>2016-02-19T11:20:04Z</dc:date>
    </item>
    <item>
      <title>Re: Pivot Table - Avg last 5 days</title>
      <link>https://community.qlik.com/t5/QlikView/Pivot-Table-Avg-last-5-days/m-p/1069412#M357300</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Didn't realize Date was a dimension, try this:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;RangeAvg(Before(Sum(Amount), 0, 5))&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;&lt;BR /&gt;&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;&lt;IMG alt="Capture.PNG" class="jive-image image-1" src="https://community.qlik.com/legacyfs/online/115248_Capture.PNG" style="height: 88px; width: 620px;" /&gt;&lt;BR /&gt;&lt;/STRONG&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 19 Feb 2016 11:21:46 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Pivot-Table-Avg-last-5-days/m-p/1069412#M357300</guid>
      <dc:creator>sunny_talwar</dc:creator>
      <dc:date>2016-02-19T11:21:46Z</dc:date>
    </item>
    <item>
      <title>Re: Pivot Table - Avg last 5 days</title>
      <link>https://community.qlik.com/t5/QlikView/Pivot-Table-Avg-last-5-days/m-p/1069413#M357301</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Great!&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 19 Feb 2016 11:26:05 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Pivot-Table-Avg-last-5-days/m-p/1069413#M357301</guid>
      <dc:creator>pamaxeed</dc:creator>
      <dc:date>2016-02-19T11:26:05Z</dc:date>
    </item>
    <item>
      <title>Re: Pivot Table - Avg last 5 days</title>
      <link>https://community.qlik.com/t5/QlikView/Pivot-Table-Avg-last-5-days/m-p/1069414#M357302</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi, &lt;SPAN class="font-color-meta" style="padding: 0 0 5px; font-size: 1.2em; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; color: #8b8b8b; background-color: #e6e6e6;"&gt;&lt;SPAN class="replyToName" style="font-weight: inherit; font-style: inherit; font-size: 15.6px; font-family: inherit;"&gt;Patric Amatulli&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Try:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;AVG({&amp;lt;&lt;SPAN style="color: #3d3d3d; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; font-size: 13px;"&gt;[Ref Date]&lt;/SPAN&gt; = {"&amp;gt;=$(=DATE(Max(&lt;SPAN style="color: #3d3d3d; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; font-size: 13px;"&gt;[Ref Date]&lt;/SPAN&gt;)-5)) &amp;lt;=$(=Max( Date(&lt;SPAN style="color: #3d3d3d; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; font-size: 13px;"&gt;[Ref Date]&lt;/SPAN&gt;)))"}&amp;gt;} &lt;SPAN style="color: #3d3d3d; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; font-size: 13px;"&gt;AMOUNT_BU&lt;/SPAN&gt;)&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;&lt;BR /&gt;&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;Hope this helps!&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 19 Feb 2016 11:28:51 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Pivot-Table-Avg-last-5-days/m-p/1069414#M357302</guid>
      <dc:creator>jonas_rezende</dc:creator>
      <dc:date>2016-02-19T11:28:51Z</dc:date>
    </item>
    <item>
      <title>Re: Pivot Table - Avg last 5 days</title>
      <link>https://community.qlik.com/t5/QlikView/Pivot-Table-Avg-last-5-days/m-p/1069415#M357303</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;And just make sure to change the expression to this:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG style="font-size: 13px; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; color: #3d3d3d;"&gt;RangeAvg(&lt;SPAN style="color: #ff0000;"&gt;After&lt;/SPAN&gt;(Sum(Amount), 0, 5))&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;if you plan to change the sorting from Ascending to Descending&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 19 Feb 2016 11:32:34 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Pivot-Table-Avg-last-5-days/m-p/1069415#M357303</guid>
      <dc:creator>sunny_talwar</dc:creator>
      <dc:date>2016-02-19T11:32:34Z</dc:date>
    </item>
  </channel>
</rss>

