Skip to main content
Announcements
Introducing a new Enhanced File Management feature in Qlik Cloud! GET THE DETAILS!
cancel
Showing results for 
Search instead for 
Did you mean: 
Not applicable

Master Calendar Overview

hey guys...I'm new to the master calendar concept. Could any of you please give me a quick overview of how to address the problem below -

I'm working on an Inventory Accuracy Report. There are 2 tables - one called Counts which contains 2 date fields "Count Created Date" and "Count Completed Date", second one called Adjustments which contains 2 date fields "Adj Created Date" and "Adj Completed Date".

I have various calculations based on each of these 4 different dates separately.

I'm trying to have one single calendar that ties these 4 dates together so that the selected dates should determine the calculations appropriately corresponding each of those 4 different dates.

Your suggestions would be greatly appreciated.

2 Replies
Oleg_Troyansky
Partner Ambassador/MVP
Partner Ambassador/MVP

Generally (or rather traditionally) speaking, - 4 dates require 4 distinct Calendars - then, however, it's hard to position them on on the same time line of years, months etc...

Another, more advanced, data structure, could be built, where the date field is the same, but the quantities and counters could be different - for example, each Count record could be split into 2 records with the field Date and with the counters - "Count Created Counter" = 1 where the Date = Count Created Date and "Count Completed Counter" = 1 where Date = Count Completed Date. This way, you could have a single time line but different expressions for dirrefent events. Your number of rows needs to double in order to implement this approach.

Finally, if you are using ver. 8.5 or 9, you could use a single detached calendar and build Set Analysis expressions comparing your 4 different dates with the Date in your "Detached" calendar. This way, you don't have to work hard on the data model, but every expression will have to be turned into a Set Analysis expression.

cheers,

Oleg

johnw
Champion III
Champion III

It sounds like you want to select a month, for instance, and then depending on the chart, see data with different dates that match that month. So one chart would show data with a "Count Created Date" in that month, and another would show data with a "Adj Completed Date" in that month. These two charts might not be showing the same records at all, and they might both be showing at the same time.

I think your only solution for that is the detached calendar like Oleg mentioned. It also technically doesn't required set analysis, so you can do it in earlier versions as well. Make a detached calendar with Date, Month, Year, whatever calendar fields you want. On the expression side, unless you run into serious performance issues, I'd probably stick with a simple IF:

sum(if("Count Created Date"="Date",Value))

In preference to a complicated set analysis expression:

sum({<"Count Created Date"={$(=chr(39)&concat("Date",chr(39)&','&chr(39))&chr(39))}>}Value)

Also, the expression is untested, and I don't guarantee that set analysis would be faster. It would just be worth performance testing both options if you ran into performance issues.