Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
Hi. I'm new to QlikView and needing help. My concern is that I can't get the correct values when there are no current selections.
I used the expression:
=Sum({$<QUARTER=P({1<MONTH={$(vMinMonth)}>}QUARTER)>}OPEN_BAL)
where:
vMinMonth =min(num(MONTH))
There's probably a syntax missing in the expressions used. Or is there a more practical way to do this? I attached a sample file for your reference. Thanks in advance.
EDIT: Used these expressions:
=sum(Aggr(If(Min(TOTAL<QUARTER> MONTH) = MONTH, sum(OPEN_BAL)),COMPANY, QUARTER, MONTH))
=sum(Aggr(If(Max(TOTAL<QUARTER> MONTH) = MONTH, sum(CLOSE_BAL)),COMPANY, QUARTER, MONTH))
Yes I do agree with sergey
So what month u select u ll get the result according to dat quarter in which dat month falls.
So, you can use my previous solution if you additionally select month
or use new file
I've just add ,QUARTER={'=MAX(QUARTER)'} to set analysis
Well, for example, if I selected only February and March (2 and 3), the minimum/earliest month of the first quarter should be the value 2. The values of the expressions should also change corresponding to those selections.
I use MAX(QUARTER) not MONTH
The values didn't change. Although, I can consider this if I can't find a dynamic solution. Thanks.
Elli Xi,
Could you clarify with example what does it mean "dynamic", what number should change in which case in your opinion?
Sorry, if I couldn't explain well. As stated above, if I selected 2 and 3 for the MONTH the values of the following expressions would change correspondingly. I fixed my earlier requirement from first to being the earliest month and last to latest. From the sample situation, MONTH 2 being the earliest and 3 the latest.
Was able to get these expressions:
=sum(Aggr(If(Min(TOTAL<QUARTER> MONTH) = MONTH, sum(OPEN_BAL)),COMPANY, QUARTER, MONTH))
=sum(Aggr(If(Max(TOTAL<QUARTER> MONTH) = MONTH, sum(CLOSE_BAL)),COMPANY, QUARTER, MONTH))
Hi Elli,
You Can try the another way which have mention the below attach Sample_QuarterMonth.QVW
Hi, thanks for this, it helped me with similar problem.
Do you have any idea how to write the dynamic label for the Open Balance and Closing Balance expressions?
So within each quarter's label, the Min month (open bal) and Max month (close bal) would be shown relative to that quarter?
Thanks!