
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
showing Month + Year in a chart
I have created a timedrill, but I want to know how to limit the Timedrill, so you have to choose Year before month etc.
Also I woundering how to display Month + Year with a chart, when using a Timedrill - because now my charts sums numbers fra May of both 2011 and 2012, if I dont choose a year?
Accepted Solutions

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Hm,
Try:
Dual(Month(Created) & ' ' & Year(Created),year(Created) & num(month(Created), '00')) as YearMonth
This should create a YearMonth value that looks like this: Jun 2011
But has an underlying value of 201111 which should help when sorting the dimension numerically so Apr 2011 doesn't come before Jun 2011 for example.

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
You could add a calculation condition to the chart to only calculate if a single year is selected?
if(Count(Year)=1,1,0)
Or perhaps use set analysis to calculate the chart for the maximum selected year?
Or create a drill down group where you show the chart by year and then when a user clicks on a year it drills down to the month level?

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
What I would like is just that eacj bar group has "Jun 2011" instead of just "Jun"

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Oh, ok.
Nicest approach would be to define a MonthYear field in your calendar in the script and use that as the dimension.

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
I apologize, but I'm a newbie at qlikview 🙂
I am not able to define a MonthYear in the script?
Are I'm in the right place?

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Hm,
Try:
Dual(Month(Created) & ' ' & Year(Created),year(Created) & num(month(Created), '00')) as YearMonth
This should create a YearMonth value that looks like this: Jun 2011
But has an underlying value of 201111 which should help when sorting the dimension numerically so Apr 2011 doesn't come before Jun 2011 for example.

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
WoW thanks man!
Help me a lot 🙂
Should I add the YearMonth to the timedrill?

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Yes, try replacing the dimension with YearMonth. However, now you will have X * 12 dimension values instead of 12 (X of course being the number of years you have data for).
