FIX: Dimension Wizard Calculates Years Incorrectly On Time Dimensions

Article translations Article translations
Article ID: 248615 - View products that this article applies to.
This article was previously published under Q248615
This article has been archived. It is offered "as is" and will no longer be updated.
BUG #: 1356 (plato7x)
Expand all | Collapse all

SYMPTOMS

When a user creates a time dimension using the OLAP Manager dimension wizard and selects a year to be a non-calendar year (such as fiscal years starting on October 1st), the year part of the date is created incorrectly. For example, October 1 1997 to September 30 1998 is created as year 1997 rather than year 1998.

WORKAROUND

After the dimension has been created, you can change the Member Key Column property of the year level in the dimension editor. This property typically defines the SELECT part of the SQL statement sent to the underlying relational database. In the preceding example, with SQL Server as the underlying database, the Member Key Column property of year level shows the following formula in dimension editor:
DatePart('yyyy',iif (Month("time_by_day"."the_date") < 10 or
(Month("time_by_day"."the_date") = 10 and
Day("time_by_day"."the_date") < 1),DateAdd('yyyy', -1,
"time_by_day"."the_date"), "time_by_day"."the_date"))
				
However, you can change the formula manually as follows to attain the desired result:
DatePart('yyyy',iif (Month("time_by_day"."the_date") < 10 or
(Month("time_by_day"."the_date") = 10 and
Day("time_by_day"."the_date") < 1),"time_by_day"."the_date",
DateAdd('yyyy', 1, "time_by_day"."the_date")))
				

STATUS

Microsoft has confirmed this to be a problem in SQL Server 7.0. This problem has been corrected in U.S. Service Pack 2 for Microsoft SQL Server 7.0. For more information, click the following article number to view the article in the Microsoft Knowledge Base:
254561 INF: How to Obtain Service Pack 2 for Microsoft SQL Server 7.0 and Microsoft Data Engine (MSDE) 1.0
For more information, contact your primary support provider.

Properties

Article ID: 248615 - Last Review: February 28, 2014 - Revision: 4.1
APPLIES TO
  • Microsoft SQL Server OLAP Services
Keywords: 
kbnosurvey kbarchive kbbug kbfix KB248615

Contact us for more help

Contact us for more help
Connect with Answer Desk for expert help.
Get more support from smallbusiness.support.microsoft.com