Qlik Community

New to QlikView

Discussion board where members can get started with QlikView.

Announcements
Leverage your QlikView investment to modernize BI – see how! Join Group
cancel
Showing results for 
Search instead for 
Did you mean: 
Highlighted
Contributor II
Contributor II

How to display data based on current selection

Hi All,

How to display last 1 year data Based on current selection month.
Example - if I select February month of 2019 year, It should display March  2018 to Feb 2019 data.

Thanks,
Vinod

1 Solution

Accepted Solutions
Highlighted
Partner
Partner

Re: How to display data based on current selection

You can accomplish this by implementing set analysis into your expression.
See my example below. Please observ that you should clear all selectable calendar fields. I cleared Year, YearMonth and Month, but you should adjust these to your field names.

=SUM({<
YearMonth,
Month,
Year,
DateField = {">=$(=monthstart(max(DateField),-11)) <=$(=max(DateField))"}
>} YourValueField)
Plees ekskuse my Swenglish and or Norweglish spelling misstakes

View solution in original post

2 Replies
Highlighted
MVP
MVP

Re: How to display data based on current selection

You can use set analysis to get it. Try to share your sample app to get more specified expression.
Highlighted
Partner
Partner

Re: How to display data based on current selection

You can accomplish this by implementing set analysis into your expression.
See my example below. Please observ that you should clear all selectable calendar fields. I cleared Year, YearMonth and Month, but you should adjust these to your field names.

=SUM({<
YearMonth,
Month,
Year,
DateField = {">=$(=monthstart(max(DateField),-11)) <=$(=max(DateField))"}
>} YourValueField)
Plees ekskuse my Swenglish and or Norweglish spelling misstakes

View solution in original post