Creating annual reports that group data by week

With a little SQL you can group your timesheet data by week...

This blog post discusses how you can create an annual timesheet report that groups or summarizes data by week. Normally when running timesheet reports, such as Employee Hours, the data is totaled for the entire reporting period. For example, the Employee Hours by Task report looks something like this when run year-to-date:

Employee Hours by Task

You can have this report summarize the data in weekly groups by using the following SQL as a grouping:

STR_TO_DATE(CONCAT(YEARWEEK(t_timeentry.strt,0),'0'),'%x%v%w')

This SQL is only valid for MySQL, but similar constructs can be made for Microsoft SQL Server and Oracle. When you group by this expression the hours data will now look like this:

Employee Hours by Task - Weekly

Here you see the same data, only summarized by the week of the year. You can contact Pacific Timesheet support or your application specialist for a more detailed solution document that describes how to do this.