Qlik Community

New to QlikView

Discussion board where members can get started with QlikView.

Announcements
Attend QlikWorld 2020 and hear keynote speaker, Malcolm Gladwell. Register by February 29th to save $200. Learn More
jtanguay
Contributor

Master Calendar and flag question

I know there is a lot of information about Master Calendars out there, but I could not seem to find exactly what I am looking for.  I have a data set with Year, Month, and Year-Month fields.  What benefits would I see in incorporating a master calendar where day, week, and time is not needed.  If there are benefits, how could I add in a simpler master calendar given my 3 field needs?

Also, how can I flag the current month in data representations where I am looking to graph this year vs. next year?  I am looking to have a dynamic view that shows up to the current month with no selections (and no more), and then will change as the users make selections.

Tags (2)
3 Replies
Highlighted
MVP & Luminary
MVP & Luminary

Re: Master Calendar and flag question

If you don't need the extra fields then don't create them.

Or adapt an existing master calendar generating script and comment out the lines that create fields you don't need.

Or use an existing master calendar generating script to create all the fields and simply drop the extra fields at the end: drop fields day, week, ...etc... ;

When you create the master calendar you can create a flag field to mark the current month:

InMonth(MyDateField, today()) as IsCurrentMonth


talk is cheap, supply exceeds demand
Highlighted
jtanguay
Contributor

Re: Master Calendar and flag question

Gysbert,

Any recommendations on a current Master calendar script out there that would work well with these few fields?

And on the second point, would the script look as such:

InMonth(Month, Today()) as IsCurrentMonth

InMonth(Month, Today(-1)) as IsPastMonth

InMonth(Month,Today(-12)) as IsPastYear

And how would you get YTD flags with this method?

Thanks for the help,

Justin

Highlighted
MVP & Luminary
MVP & Luminary

Re: Master Calendar and flag question

Not quite. Look up the InMonth and other In* functions in the help file like the InYearToDate function.

Maybe this blog post (and the comments!) helps: Year-over-Year Comparisons

You may be interesting in this blog post as well: http://www.quickintelligence.co.uk/qlikview-calendar/


talk is cheap, supply exceeds demand