A*******n 发帖数: 625 | 1 请教一个问题,like:
CubeName (Invoice)
Dimension Name (CustomerName, CustomerTypeStatus,.....)
Measure (Amt)
------
CustomerName (CustKey,CustName,CustNo)
CustomerTypeStatus (Type, status)
tables的关系是(4 tables):
InvoiceDetail-->Invoice-->Customer
InvoiceDetail-->Category
CustomerName和CustomerTypeStatus 的数据都来自于Customer,在sql server 2000没
什么问题,可是在2008就有问题,当我run query的时候:
SELECT { [Customer Type Status].[All Customer Type Status].[C],
[Customer Type Status].[All Customer Type Status].[O],
[Customer Type Status].[All Customer Type Status].[R] } ON COLUMNS ,
{ [Customer Name].[All Customer Name].[#],
[Customer Name].[All Customer Name].[#].[#1 HAIR SALON (60538)] } ON ROWS
FROM [Invoice]
结果就乱了。
我记的在SQL Server BIDS 2008打开cube-->Dimension Usage,如果dimension 和
measure groups没有直接关系的话,结果就不对是不是?
各位老大给点意见,谢谢了。 | g***l 发帖数: 18555 | 2 我是初学的,我觉得这个CUBE应该有两个DIMENSION吧,一个是CUSTOMER,一个是ORDER(
或者INVOICE),ORDER DETAIL在ORDER下面,可以做成SNOWFLAKE,或者把ORDR HEADER+
DETAIL做成一个,STAR SCHEMA,你的DIMENSION NAME看着很怪异Dimension Name (
CustomerName, CustomerTypeStatus,.....) | A*******n 发帖数: 625 | 3 你也觉的怪吧,这是其他人在N年前做的,是sql server 2000的,
Dimensions include:
1.Customer Name
1.1 Cust Key
1.2 Cust Name
1.3 Cust No
2. Customer Type Status
2.1 Cust Type
2.2 Cust Status
还有几个dimensions,先用这2个,
SELECT { [Customer Type Status].[All Customer Type Status].[C],
[Customer Type Status].[All Customer Type Status].[O],
[Customer Type Status].[All Customer Type Status].[R] } ON COLUMNS ,
{ [Customer Name].[All Customer Name].[#],
[Customer Name].[All Customer Name].[#].[#1 HAIR SALON (60538)] } ON ROWS
FROM [Invoice]
结果就是
C O R
# 469.74
#1 HAIR SALON (60538) 469.74
可是在2008就乱了,全是同样的值。 都是同样的值我想是因为dimension(Customer
Name,Customer Type Status)和 measure没直接的关系,可是为什么在2000里面就没什
么问题呢 | g***l 发帖数: 18555 | 4 设计根本就不对,出的值是对的也是瞎蒙的。CUSTOMER就是一个DIMENSION,STATUS要
并到CUSTOMER里去,QUERY的结果跟你的CUBE设计关系很大,设计不好QUERY很容易出错
的,可能是升级的时候RELATIONSHIP丢失了
【在 A*******n 的大作中提到】 : 你也觉的怪吧,这是其他人在N年前做的,是sql server 2000的, : Dimensions include: : 1.Customer Name : 1.1 Cust Key : 1.2 Cust Name : 1.3 Cust No : 2. Customer Type Status : 2.1 Cust Type : 2.2 Cust Status : 还有几个dimensions,先用这2个,
| i*****w 发帖数: 75 | 5 In Analysis Services 2000, most references follow the pattern of dimension.
level, in AS 2005, most references follow the pattern of dimension.hierarchy
.level
When you see all have the same value, that means the data (fact and
dimension) were not related (not sliced by the dimension at all), so SSAS
uses the default member for those dimensions, which is the "ALL" level.
【在 A*******n 的大作中提到】 : 请教一个问题,like: : CubeName (Invoice) : Dimension Name (CustomerName, CustomerTypeStatus,.....) : Measure (Amt) : ------ : CustomerName (CustKey,CustName,CustNo) : CustomerTypeStatus (Type, status) : tables的关系是(4 tables): : InvoiceDetail-->Invoice-->Customer : InvoiceDetail-->Category
|
|