InfoCube Aggregate聚集介绍

<摘自网络>

BW中聚集是指根据InfoCube中几个或者一个维度信息对象创建的小的CUBE,其实是新生成一张事实表,外加一些对应的维度表,可以提供数据的访问效率。

An aggregate is a roll up of fact data where a total value is sufficient and no detailed information is needed.

Technically speaking,an aggregate is a separate infoCube with its own fact table and dimension tables.When an aggregate is created,it is gaven six-digit number <1NNNNN> that starts with a ì1?. The table name for an aggregate is derive in the same way from this number as InfoCube table names are derived from InfoCube names.

For example, if an aggregate has the technical name 100001, its fact tables are

called /BIC/E100001 and /BIC/F100001. Its dimensions have the table names

/BIC/D100001P, /BIC/D100001T, and so on.

Dimension tables can be shared between an InfoCube and an aggregate. In this

example, dimension 2 (the country dimension) is shared between the InfoCube

and the aggregate. It is not necessary to create a new dimension table. A link to

this dimension table is created in the aggregate fact table.

聚集维度可以分为“层次结构的聚集”(H)、“固定值的聚集维度”及“一般聚集维度”;其主要用法根据实际使用来确定,例如某张报表只会访问到某个层次结构的N层次,再往下就不看了,则可以给CUBE生成一个对应的聚集,该聚集维度基于该层的“层级结构维度”。

其中对于聚集中维度数据和事实表数据的更新,如果是导航属性生成的维度表,则通过信息对象的change run可以同步聚集维度表数据,而事实表数据通过ROLL UP可以更新。

简单来说,聚集的作用是:预先计算,以空间换时间。提高Query的查询效率。

 

下图为InfoCube中的数据,即事实表中的数据,第6列为数量,第7列为合计金额,第8列为单价

InfoCube中的事实表数据

Aggregate中的数据

0FACTCOUNT代表聚集的记录数,Y2IO_QUAN为合计的数量(共合计了3条记录),Y2IO_REV为合计的金额数

Sales Price为合计的价格(无用,此记录不应该被合计)

聚集中的结果数据

转载于:https://www.cnblogs.com/spmxlBlog/archive/2011/10/18/2216424.html

  • 0
    点赞
  • 0
    收藏
    觉得还不错? 一键收藏
  • 0
    评论

“相关推荐”对你有帮助么?

  • 非常没帮助
  • 没帮助
  • 一般
  • 有帮助
  • 非常有帮助
提交
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值