Qlik Community

New to QlikView

Discussion board where members can get started with QlikView.

Announcements
Modernize Your QlikView Deployment webinar, Nov. 3rd. REGISTER
cancel
Showing results for 
Search instead for 
Did you mean: 
Highlighted
Contributor
Contributor

Load inline values and link with Chart

User selects from '2016','2015','2014' Listbox (Created by inline load below)

However, I am having some issues with linking the below,

LOAD * INLINE [

    Year

    2016

    2015

    2014

];

In my dataset I have the below columns filled with numerical values,

  • 2016 Sales
  • 2015 Sales
  • 2014 Sales

How can the Pivot Table and Pie Chart update as per user 'Year' selection?

I do not want to create 3 Charts but would rather keep it 1 Dynamic Chart that changes with 'Year' selection.

It should be something with regards to conditions/expression in both Pivot Table and Pie Chart but I am not sure of how to do it.


Would appreciate your help.

5 Replies
Highlighted
Master II
Master II

You can deal in two ways:

1) either you call your inline fields as below:

2016 Sales

2015 Sales

2014 Sales

Or

Your dataset as below:

2016

2015

2014

Hope this helps.

Highlighted
Master II
Master II

Maybe use Keepchar in your Original data set?

Keepchar( YearSales, '0123456789') as Year

You can now use Year in front end with out creating an Inline table since this new field is created from your fact table it will work for all your charts

Highlighted

May be these:

=num(Sum({1<Year={'$(=getfieldselections(Year))'}>} Sales),'0.00')

or

Sum({$<Year={'$(=getfieldselections(Year))'}>} Sales)

Highlighted

Sum({$<Year=p(Year)>} Sales)

Highlighted
MVP & Luminary
MVP & Luminary

In most cases it's better to resolve the multiple sales columns within a single column for sales and one for your period per The Crosstable Load‌. With this no extra logics to select the values will be needed.

- Marcus