FIX: OLAP Calculated Member That References Distinct Count Calculated Member Returns 0 (324905)



The information in this article applies to:

  • Microsoft SQL Server 2000 Analysis Services

This article was previously published under Q324905
BUG #: 13436 (Plato7x)

SYMPTOMS

If a calculated member references another calculated member that uses the Distinct Count Multidimensional Expression (MDX) function, and the DistinctCount calculated member is not included in the MDX query, the values returned by the calculated member may have zero values. For example:
CalcMeasureA definition 'DistinctCount(
CalcMeasureB definition ' iif([Measures].[CalcMeasureA]=0 OR 
[Measures].[CalcMeasureA]= NULL OR
Is Empty([Measures].[CalcMeasureA]), 0, [Measures].[SalesAmount]/[Measures].[CalcMeasureA])'
				
If CalcMeasureB is included in a query but CalcMeasureA is not, then the value may be 0 for all CalcMeasureB cells.

CAUSE

A problem with the DistinctCount function in the MDX.

RESOLUTION

To resolve this problem, obtain the latest service pack for Microsoft SQL Server 2000. For additional information, click the following article number to view the article in the Microsoft Knowledge Base:

290211 INF: How To Obtain the Latest SQL Server 2000 Service Pack

NOTE: The following hotfix was created before the release of Microsoft SQL Server 2000 Service Pack 3.

The English version of this fix has the file attributes (or later) that are listed in the following table. The dates and times for these files are listed in coordinated universal time (UTC). When you view the file information, it is converted to local time. To find the difference between UTC and local time, use the Time Zone tab in the Date and Time tool in Control Panel.
   Date         Time       Version         Size              File name
   -----------------------------------------------------------------------

   06/06/2002   07:22 PM   8.0.639.0       1,774,148 bytes   Msmdsrv.exe
   06/07/2002   10:36 AM   8.0.639.0       2,024,016 bytes   Msolap80.dll
   04/18/2001   01:23 AM   2000.80.382.0     815,676 bytes   Sqldata.dll
   06/07/2002   10:36 AM   2000.80.534.0     590,396 bytes   Sqlsort.dll 
				
NOTE: Because of file dependencies, the most recent hotfix or feature that contains the files may also contain additional files.

STATUS

Microsoft has confirmed that this is a problem in the Microsoft products that are listed at the beginning of this article.
This problem was first corrected in Microsoft SQL Server 2000 Service Pack 3.

Modification Type:MajorLast Reviewed:6/25/2004
Keywords:kbSQLServ2000sp3fix kbbug kbfix kbSQLServ2000preSP3fix KB324905