Modeling the Calendar
maintain calendars on these terms, allowing the user to see April 18, 2002 instead of day 198, and yet internally, such systems continue to count days based on working and nonworking days. By their very nature, factory calendars are localized. That is, each production facility may have its own factory calendar to reflect the workdays and shifts within that facility. Whether you are developing your data warehouse for a manufacturer or not, the idea of tracking workdays has wide applicability when performing analysis for a variety of businesses. The concept of the factory calendar has been expanded in modern usage to provide a calendar for consistently measuring the number of workdays between two events, such as the beginning and end of a promotional period, and for facilitating data access for an equal number of workdays regardless of the elapsed calendar days. The premise behind the factory calendar was to homogenize the timeline so that day calculations could be done using simple arithmetic. This homogeneity is also important when performing year-over-year and month-over-month analysis. If you have a sales force that works Monday through Friday and you need to compare this month’s performance to date against last month’s, it makes sense to count the same number of selling days in each month; otherwise, the comparison can be skewed depending on where the weekend falls in relation to the start of the month. This concept will be discussed at length in the next section. Calendar Elements An effective calendar entity can significantly improve people’s ability to perform analysis over time. There are three fundamental concepts that facilitate the analysis: ■■ The day of the week, particularly in Retail businesses ■■ Accounting for nonworking days to provide meaningful comparative analysis and elapsed-time calculations ■■ Defining time periods of interest, such as holiday seasons, for analysis Day of the Week The day of the week is probably the most commonly recognized special day for performing date-oriented analyses. Often the day of the week is used to distinguish between workdays and nonworkdays. Aworkday indicator in the Day of the Week entity in Figure 6.1 shows whether it is a regularly scheduled workday, and this can be used to facilitate analysis. Acompany’s revenue cycle is also sometimes dependent on the day of the week. Some retailers have a heavier daily sales volume during weekend days, while
Các file đính kèm theo tài liệu này:
- mastering_data_warehouse_design_relational_and_dimensional_techniques00005_2484.pdf