Skip to main content
Announcements
NEW: Seamless Public Data Sharing with Qlik's New Anonymous Access Capability: TELL ME MORE!
cancel
Showing results for 
Search instead for 
Did you mean: 
Not applicable

Date Function Challenges

Friends/Colleagues,

I will feel much obliged if you please provide Date Function to calculate the following.

How can I accomplish the following by each YEAR (2011 - 2012) and MONTH ( 1-12) on a Bar Chart?

Q1. Aggregate/Sum of "No Of Hits" for the "Previous Day"? E.g. Assuming today is 12/20/2011 it would be "6"

Q2. Aggregate/Sum of  "No of Hits" for the "Month to Date"? E.g. Assuming today is 12/20/2011 it would be "18"

Q3. Aggregate/Sum of  "No of Hits" for the "Year to Date"? E.g. Assuming today is 12/20/2011 it would be "21"

DateNo Of Hits
11/18/20111
11/19/20112
12/1/20113
12/5/20114
12/18/20115
12/19/20116
12/20/20110

Thank You. Happy Memorial Day

MBBS

Note: Please see attchment for more example

2 Replies
hic
Former Employee
Former Employee

First, you need to create a master calendar, i.e. an additional table with all date attributes. See more here and search on the forum for a master calendar.

Secondly, you should create a field "DagsAgo" in your master calendar, that you can use for your first question. See more here.

Thirdly, you should create flags in your calendar, e.g. "IsInYTD", that mark whether this day is within the year/month to date. See more here or search the forum for ytd or yoy.

HIC

Not applicable
Author

Dear Mr. Cronström,

I highly appreciated your quick response. I will look into your suggestions

and make a sincere effort to solve my problem.

I am really happy to take a note of the fact that this community is

really/truly active and someone is always out there to look into unanswered

questions/issues and ready to help.

Thank you and may GOD bless you.

With Kindest Regards,

Sam David

On Mon, May 26, 2014 at 3:08 PM, Henric Cronström