Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
Hi,
I have a little problem concerning a calculation with periods of dates
I does a selection into a period between 14/11/09 and 15/05/10.
My statistic is good for the calculation into the period (sum(Amount)=>Ok
I would like to compare this calculation with the same period the past year(14/11/08 --> 15/05/09)
I am a beginner into Qlikview and it's impossible to find the formula that will compare with the previous period.
Can you help me?
Thanks a lot
Mk
It could be something like this:
sum({1 <Date={"$(='>=' & AddMonths(min({$} Date), -12) & '<=' & AddMonths(max({$}Date), -12))"}>} Amount)
See the example in attachment
It could be something like this:
sum({1 <Date={"$(='>=' & AddMonths(min({$} Date), -12) & '<=' & AddMonths(max({$}Date), -12))"}>} Amount)
See the example in attachment
That's great !
All is ok !
Thanks a lot for your help
Ciao
Mk
Hi Nick and all,
I have a little problem with this expression because, since I put this calculation, the filters selected (Products,...) are not executed.
The filters are only applied into the columns without his calculation.
Can you help me?
Ciao
Michael
Dear Martelmi,
please post your qlikview application.
Regards
Sunil Jain.
Hi
Here is an extract of the file.
Thanks a lot for you help
Ciao
Try this:
=sum({<DATELIV={"$(='>=' & AddMonths(min({$} DATELIV), -12) & '<=' & AddMonths(max({$}DATELIV), -12))"}>} CAFACTURE)
Hi,
If I keep my period, the amount is null.
The '1' is essential, in my opinion( What's this number? :-))
The problem is often when the statistic does more 1 column(In the example that I sent, the problem is resolved (also more columns)but in my real file, it's not correct)and when the table is dynamic .
If you want, i can send you another file with more details but I have to work in this file(delete curtain data 🙂 ).
Thanks a lot
If you are getting null it means there is no any data for previous period - check your data and conditions.
About 1 in Set Analysis:
There is one constant that can be used to denote a record set; 1. It represents the full set of all the records in the application.
The $ sign represents the records of the current selection. The set expression {$} is thus the equivalent of not stating a set expression. {1-$} is all the more interesting as it defines the inverse of the current selection, i.e. everything that the current selection excludes.
Read more in the Help for Set Analysis.
About your Applications I can say that there are individual approaches for each individual application. Usually Cut&Past doesn't work. Think first.
To help you with your applications it always better to have a sample which duplicates a critical piece of the application or the application itself.
Hi
I check my data and I have data in the previous period.I join you the file with a particular case.
If I select one product, data , without the formula, are refreshed correctly.
But the problem is that the data, in the previous period, are refreshed for all products.
Is it possible to look this if you have any idea?
I searching in the help , in forums...
Can you help me?
Ciao