SQL Analysis Server中的维度在层次结构中不是唯一的

时间:2017-12-10 10:59:52

标签: sql-server ssas cube

我在Analysis-Server中创建了一个Dimension,类似于以下层次结构:

CountryRegion
StateProvince
City
PersonName

具有以下关系

DimCustomerID -> PersonName -> City -> StateProvince -> CountryRegion

现在,我的此维度数据包含以下行:

DimCustomerID   CustomerID  AddressID   CountryRegion   StateProvince   City        PersonName
4134            13788       19569       United Kingdom  England         Birmingham  Fernandez Kari
4717            11533       18752       United States   Alabama         Birmingham  Gill Ebony

当我尝试处理Dimension时,我收到错误

Errors in the OLAP storage engine: A duplicate attribute key has been found when processing: Table: 'BI_DimCustomer', Column: 'City', Value: 'Birmingham'. The attribute is 'City'.

我知道,伯明翰市与不同的州政府重复。但他们也有两个不同的CountryRegions。

我该怎么做才能让它运转起来?

谢谢。

1 个答案:

答案 0 :(得分:1)