Qlik Community

Qlik Sense App Development

Discussion board where members can learn more about Qlik Sense App Development and Usage.

Not applicable

Straight table issue

I am using Qliksense

Attached please find the sample data, sample qvw and screen shot.  I have a Year and Launch Year fields.  So In each Year I can have multiple Launch Years, for example  Year=2016 will have launch Years 2016,2015,2014 etc

for Year 2015  will have launch Years 2016,2015,2014 etc.

Now I want to use the following grouping:

=If(LaunchYear >= Year,'<1 Year',

If(LaunchYear >= (Year-2) and LaunchYear < Year,'Prior 2 Years',

If(LaunchYear <= (Year-3), 'Prior 3 Year')))

But at the same time I want to exclude any future Launch Years. For  example , If I am in Year 2015, I  want to see only Launch Years <= 2015 and then in the last column I would to sum the total for each Year.

Looking for the solution

12 Replies
MVP
MVP

Re: Straight table issue

Try this:

=If(LaunchYear = Year,'<1 Year',

If(LaunchYear >= (Year-2) and LaunchYear < Year,'Prior 2 Years',

If(LaunchYear <= (Year-3), 'Prior 3 Year')))

Removed the greater than sign here (=If(LaunchYear >= Year,'<1 Year',)

also selected 'Suppress When Value Is Null'

Capture.PNG

Not applicable

Re: Straight table issue

I am using Qlik Sense

Not applicable

Re: Straight table issue

Also the total is not working.  Total should be the same for all rows for Year 2016, 2015 and 2014

MVP
MVP

Re: Straight table issue

Why did you post a QlikView sample? Can you post a QlikSense sample to check the issue?

Not applicable

Re: Straight table issue

Let me do that then

Not applicable

Re: Straight table issue

Attached is the sample QVF

MVP
MVP

Re: Straight table issue

This?

Capture.PNG

What is wrong with the total? What do you want to see?

Not applicable

Re: Straight table issue

The sample qvf you sent works, but when I amsuing the same info on the actual data set the total is nor working.  I am getting the total for the dimension Launch condition.

My expression for total is

Sum(  total <Year> SPLTQTY)

What am I missing here?

MVP
MVP

Re: Straight table issue

Can you try this:

Aggr(NODISTINCT Sum(SPLTQTY), Year)