Skip to main content
Announcements
Qlik Connect 2024! Seize endless possibilities! LEARN MORE
cancel
Showing results for 
Search instead for 
Did you mean: 
Not applicable

Set Analysis, Previous Period, Change on Diemension

Hi,

Looking forward to solutions to the following situation:

Show Previous Year Total (single figure ) based on current selections in the Year Field

Selections in the Quarter, Month and Day should not cause recalculation in the Previous Year Total

However, selection on other dimensions (Country, City, Product, Category) should cause recalculation in the Previous Year Total.

thanks in advance !

4 Replies
sunny_talwar

May be this:

=Sum({<Year = {"$(=Max(Year) - 1)"}, Quarter = , Month = , Day = >} FieldName)

Not applicable
Author

No this is not going to work. since, the year field is already selected therefore rest of the data is filtered and previous year could never be selected. For this i will have to use 1 instead of $. But the problem is that the data will remain the same. However, i want it to change on some dimensions and not on some dimensions and still be able to use current selection to calculate previous year.

I have figured out a way and seems to have worked nevertheless the results are not accurate. I have used following:

Sum( {
1  <
[Fiscal Month #]=,
Day=,
Quarter=,
[Fiscal Year #] =  { $(=Max( [Fiscal Year #])-1 )  }
,
Country = p({$} Country) ,
City = p({$} City),
Group = p({$} Group),
[Sub-Category] = p({$} [Sub-Category]),
[Product Details] = p( {$} [Product Details])
>
} Amount )
sunny_talwar

What do you exactly mean when you say the results are not accurate? What is the problem?

qlikviewwizard
Master II
Master II

Hi,

Can you attach the sample file with the data?