<?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: display data in a bar chart for rolling 2 years in QlikView</title>
    <link>https://community.qlik.com/t5/QlikView/display-data-in-a-bar-chart-for-rolling-2-years/m-p/1759172#M453937</link>
    <description>&lt;P&gt;Hi Zhaofeng,&lt;/P&gt;&lt;P&gt;&amp;nbsp;The expression is not working, it displays no data in the chart.&lt;/P&gt;&lt;P&gt;can we try any other way?&lt;/P&gt;</description>
    <pubDate>Fri, 06 Nov 2020 03:57:27 GMT</pubDate>
    <dc:creator>analyticsuser</dc:creator>
    <dc:date>2020-11-06T03:57:27Z</dc:date>
    <item>
      <title>display data in a bar chart for rolling 2 years</title>
      <link>https://community.qlik.com/t5/QlikView/display-data-in-a-bar-chart-for-rolling-2-years/m-p/1759161#M453933</link>
      <description>&lt;P&gt;I have a bar chart that has to display data for rolling 2 years. For 2018, it has to display count(responses) and when 2019 is selected - it has to display unique set of responses for 2018 and 2019. Do I use a calculated dimension on year or an expression would work? Please refer to the attached file. Any quick help would be greatly appreciated.&lt;/P&gt;</description>
      <pubDate>Fri, 06 Nov 2020 02:32:07 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/display-data-in-a-bar-chart-for-rolling-2-years/m-p/1759161#M453933</guid>
      <dc:creator>analyticsuser</dc:creator>
      <dc:date>2020-11-06T02:32:07Z</dc:date>
    </item>
    <item>
      <title>Re: display data in a bar chart for rolling 2 years</title>
      <link>https://community.qlik.com/t5/QlikView/display-data-in-a-bar-chart-for-rolling-2-years/m-p/1759162#M453934</link>
      <description>&lt;P&gt;Hi&lt;/P&gt;&lt;P&gt;I think you can use variable to solve it.&lt;/P&gt;&lt;P&gt;First,you need to set a variable named "v_year" and the variable formula is&amp;nbsp; =max(year)-2&lt;/P&gt;&lt;P&gt;Then,your expression is&amp;nbsp; &amp;nbsp;count({&amp;lt;Year={"&amp;gt;=$(v_year)"}&amp;gt;}&lt;SPAN&gt;responses&lt;/SPAN&gt;)&lt;/P&gt;&lt;P&gt;You can try it and check the result&lt;/P&gt;</description>
      <pubDate>Fri, 06 Nov 2020 02:39:37 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/display-data-in-a-bar-chart-for-rolling-2-years/m-p/1759162#M453934</guid>
      <dc:creator>zhaofeng</dc:creator>
      <dc:date>2020-11-06T02:39:37Z</dc:date>
    </item>
    <item>
      <title>Re: display data in a bar chart for rolling 2 years</title>
      <link>https://community.qlik.com/t5/QlikView/display-data-in-a-bar-chart-for-rolling-2-years/m-p/1759164#M453935</link>
      <description>&lt;P&gt;Thanks zhaofeng. The expression doesn't work.&lt;/P&gt;&lt;P&gt;If I select 2018, the count (responses) is 610.&lt;/P&gt;&lt;P&gt;If I select 2019, the count(responses) is 730.&lt;/P&gt;&lt;P&gt;But, when displaying in the bar chart , for year = 2019, the user wants to display count(distinct responses) for 2018 &amp;amp; 2019 combined, which is 690.&lt;/P&gt;&lt;P&gt;How do I achieve this using set expression or calculated dimension?&lt;/P&gt;</description>
      <pubDate>Fri, 06 Nov 2020 03:12:43 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/display-data-in-a-bar-chart-for-rolling-2-years/m-p/1759164#M453935</guid>
      <dc:creator>analyticsuser</dc:creator>
      <dc:date>2020-11-06T03:12:43Z</dc:date>
    </item>
    <item>
      <title>Re: display data in a bar chart for rolling 2 years</title>
      <link>https://community.qlik.com/t5/QlikView/display-data-in-a-bar-chart-for-rolling-2-years/m-p/1759165#M453936</link>
      <description>&lt;P&gt;Oops,sorry,I've misread what you said&lt;/P&gt;&lt;P&gt;You can try this.&lt;/P&gt;&lt;P&gt;You need two variables.For example v_start and v_end&lt;/P&gt;&lt;P&gt;v_start = max(year)-1&lt;/P&gt;&lt;P&gt;v_end = max(year)&lt;/P&gt;&lt;P&gt;Your expression is&amp;nbsp; &amp;nbsp;&lt;SPAN&gt;count({&amp;lt;Year={"&amp;gt;=$(v_year)&amp;lt;=$(v_end)"}&amp;gt;} distinct&amp;nbsp;&lt;/SPAN&gt;&lt;SPAN&gt;responses&lt;/SPAN&gt;&lt;SPAN&gt;)&lt;/SPAN&gt;&lt;/P&gt;</description>
      <pubDate>Fri, 06 Nov 2020 03:36:26 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/display-data-in-a-bar-chart-for-rolling-2-years/m-p/1759165#M453936</guid>
      <dc:creator>zhaofeng</dc:creator>
      <dc:date>2020-11-06T03:36:26Z</dc:date>
    </item>
    <item>
      <title>Re: display data in a bar chart for rolling 2 years</title>
      <link>https://community.qlik.com/t5/QlikView/display-data-in-a-bar-chart-for-rolling-2-years/m-p/1759172#M453937</link>
      <description>&lt;P&gt;Hi Zhaofeng,&lt;/P&gt;&lt;P&gt;&amp;nbsp;The expression is not working, it displays no data in the chart.&lt;/P&gt;&lt;P&gt;can we try any other way?&lt;/P&gt;</description>
      <pubDate>Fri, 06 Nov 2020 03:57:27 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/display-data-in-a-bar-chart-for-rolling-2-years/m-p/1759172#M453937</guid>
      <dc:creator>analyticsuser</dc:creator>
      <dc:date>2020-11-06T03:57:27Z</dc:date>
    </item>
    <item>
      <title>Re: display data in a bar chart for rolling 2 years</title>
      <link>https://community.qlik.com/t5/QlikView/display-data-in-a-bar-chart-for-rolling-2-years/m-p/1759190#M453939</link>
      <description>&lt;P&gt;I've made a example,you can check it.&lt;/P&gt;</description>
      <pubDate>Fri, 06 Nov 2020 06:08:22 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/display-data-in-a-bar-chart-for-rolling-2-years/m-p/1759190#M453939</guid>
      <dc:creator>zhaofeng</dc:creator>
      <dc:date>2020-11-06T06:08:22Z</dc:date>
    </item>
    <item>
      <title>Re: display data in a bar chart for rolling 2 years</title>
      <link>https://community.qlik.com/t5/QlikView/display-data-in-a-bar-chart-for-rolling-2-years/m-p/1759193#M453940</link>
      <description>&lt;P&gt;I'm not able to look at your attachments at the moment, but maybe somethingllike this is what you are looking for?&lt;/P&gt;&lt;P&gt;Sum( aggr( rangesum( above( count(Responses),0,2) ),Year))&lt;/P&gt;&lt;P&gt;You could also take a look into &lt;a href="https://community.qlik.com/t5/user/viewprofilepage/user-id/18624"&gt;@Gysbert_Wassenaar&lt;/a&gt;&amp;nbsp;old blog post from 2013, &lt;A href="https://community.qlik.com/t5/QlikView-Documents/Calculating-rolling-n-period-totals-averages-or-other/ta-p/1483033" target="_self"&gt;Calculating rolling n-period totals, averages or other aggregations&lt;/A&gt;.&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Fri, 06 Nov 2020 06:34:03 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/display-data-in-a-bar-chart-for-rolling-2-years/m-p/1759193#M453940</guid>
      <dc:creator>Vegar</dc:creator>
      <dc:date>2020-11-06T06:34:03Z</dc:date>
    </item>
    <item>
      <title>Re: display data in a bar chart for rolling 2 years</title>
      <link>https://community.qlik.com/t5/QlikView/display-data-in-a-bar-chart-for-rolling-2-years/m-p/1759199#M453941</link>
      <description>&lt;P&gt;thank you for the example. When I'm trying to implement the same expression in the bar chart with dimension as Year, somehow the data is not being displayed.&lt;BR /&gt;I'm using the expression - count({&amp;lt;Year={"&amp;gt;=$(vYearStart)&amp;lt;=$(vYearEnd)"}&amp;gt;} distinct Responses)&lt;BR /&gt;vYearStart = max(Year) - 1 :2018&lt;BR /&gt;vYearEnd = max(Year) : 2019&lt;/P&gt;</description>
      <pubDate>Fri, 06 Nov 2020 07:06:30 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/display-data-in-a-bar-chart-for-rolling-2-years/m-p/1759199#M453941</guid>
      <dc:creator>analyticsuser</dc:creator>
      <dc:date>2020-11-06T07:06:30Z</dc:date>
    </item>
    <item>
      <title>Re: display data in a bar chart for rolling 2 years</title>
      <link>https://community.qlik.com/t5/QlikView/display-data-in-a-bar-chart-for-rolling-2-years/m-p/1759200#M453942</link>
      <description>&lt;P&gt;Thank you Vegar. The expression works but not the way I want it to.&lt;BR /&gt;When 2018 is selected, it should show just the count of responses for 2018.&lt;BR /&gt;When 2019 is selected, the bar graph should show the combined count of responses for 2018,2019 .&lt;/P&gt;</description>
      <pubDate>Fri, 06 Nov 2020 07:06:58 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/display-data-in-a-bar-chart-for-rolling-2-years/m-p/1759200#M453942</guid>
      <dc:creator>analyticsuser</dc:creator>
      <dc:date>2020-11-06T07:06:58Z</dc:date>
    </item>
  </channel>
</rss>

