查看: 5374|回复: 20

[原创] 关于数据仓库系统设计的问题,欢迎大家共同参与讨论!

[复制链接]
论坛徽章:
181
慢羊羊
日期:2015-03-04 14:19:442015年新春福章
日期:2015-03-06 11:57:31
跳转到指定楼层
1#
发表于 2006-11-9 23:06 | 只看该作者 回帖奖励 |倒序浏览 |阅读模式
本文主要以SQLServer和Analysis Service为例。结合自己在开发数据仓库过程中的经验教训,介绍数据仓库项目的设计优化ETL处理过程等,期间会可能扩展开来讲一些其他的数据库。
文中的英文部分(主要懒得进行翻译了),会在帖出后不断进行修改。请大家不要介意。有兴趣也可以参看本人的Blog。
当然对于数据仓库的概念,还是摘选原文的,翻译过来反而失真,就不敢翻译了。
因本人水平有限,希望大家多多提出宝贵意见!
论坛徽章:
181
慢羊羊
日期:2015-03-04 14:19:442015年新春福章
日期:2015-03-06 11:57:31
2#
 楼主| 发表于 2006-11-9 23:08 | 只看该作者
SQL Server 2000 & Analysis Service

纲要

数据仓库概念
数据库设计(物理设计和逻辑设计)
备份

使用道具 举报

回复
论坛徽章:
181
慢羊羊
日期:2015-03-04 14:19:442015年新春福章
日期:2015-03-06 11:57:31
3#
 楼主| 发表于 2006-11-9 23:11 | 只看该作者
数据仓库概念
   A data warehouse is a subject-oriented, integrated, nonvolatile, time-variant collection of data designed to support management DSS needs.
  数据仓库就是面向主题的、集成的、稳定的、不同时间的数据集合,用以支持经营管理中的决策制定过程。目的是解决在信息技术(IT) 发展中存在的拥有大量数据、而有用信息贫乏(Data rich-Information poor)的问题。

使用道具 举报

回复
论坛徽章:
181
慢羊羊
日期:2015-03-04 14:19:442015年新春福章
日期:2015-03-06 11:57:31
4#
 楼主| 发表于 2006-11-9 23:17 | 只看该作者
一、基于主题的
Subject-Oriented data is organized around major subject areas of an enterprise and is useful for an enterprise-wide understanding of those subjects. For Example, a banking operational system maintains independent records of customer savings, loans, and other transactions. A warehouse pulls this independent data together to provide financial information.
The data from diverse sources is transformed so that it is consistent and meaningful for the warehouse.
因此,主要的工作如下:
1、事实表的设计
2、不同数据源业务数据的获取.
3、维度的设计
4、度量值的设计
5、星型模型和雪花模型的设计
6、OLAP模型的设计

使用道具 举报

回复
论坛徽章:
181
慢羊羊
日期:2015-03-04 14:19:442015年新春福章
日期:2015-03-06 11:57:31
5#
 楼主| 发表于 2006-11-9 23:22 | 只看该作者
二、集成的
Data on a given subject is integrated.
In many organizations, data resides in diverse independent systems, making it difficult to integrate the information into a single set of meaningful data from analysis. A key characteristic of a warehouse is that data is completely consolidated or integrated. Data is structured in a globally accepted manner, even when the underlying source data is structured differently (conforming dimension). Integration and transformation processes can be time-consuming and costly. It requires commitment from every part of the organization, particularly top-level managers who make the decisions and allocate resources and funds.
因此,主要的工作如下:
1、同一不同组织的维度体系
2、维度表的设计(关于非空和约束机制)
3、中间转换表
4、维度的处理方式
需要注意的是:
我们无法控制和识别人为的错误。

使用道具 举报

回复
论坛徽章:
181
慢羊羊
日期:2015-03-04 14:19:442015年新春福章
日期:2015-03-06 11:57:31
6#
 楼主| 发表于 2006-11-9 23:29 | 只看该作者
三、稳定的(有的翻译为非易失的)
Typically, data in the data warehouse is read-only (less volatile than operational systems). Data is loaded into the data warehouse for the first-time load, and then refreshed regularly. Warehouse data is accessed by business users. Warehouse operations typically involve:
Loading the initial set of warehouse data (often called the first-time load)
因此,主要的工作如下:
1、DTS的设计和调度计划
2、维度数据必须是增量的,也就是说维度数据只能更新和插入,不能被删除(否则无法保证历史数据的持续性)。而且在一定程度上维度值是唯一的。
3、事实表数据和原始业务数据也是增量的,实际上根据业务需要和物理存储的要求,它可能也会被做更新和删除。当数据量太大时,全量的数据处理将会变得不可能。

使用道具 举报

回复
论坛徽章:
181
慢羊羊
日期:2015-03-04 14:19:442015年新春福章
日期:2015-03-06 11:57:31
7#
 楼主| 发表于 2006-11-9 23:35 | 只看该作者
四、不同时间的
Warehouse data is by nature historical; data is retained for a long time, from two to ten years, compared with one to three months of data for a typical operational system. The data allows for analysis of past and present trends, and for forecasting, using what-if scenarios.
基于时间增量和数据库数据存储的考虑,必须关注以下几个方面:
1、数据库的整体设计
2、数据库表的设计
3、OLAP的增量策略

使用道具 举报

回复
论坛徽章:
181
慢羊羊
日期:2015-03-04 14:19:442015年新春福章
日期:2015-03-06 11:57:31
8#
 楼主| 发表于 2006-11-9 23:40 | 只看该作者
数据库设计

1、数据库整体结构设计
2、文件组的应用和设计
3、历史数据表和临时数据表的区分设计
4、分区表的设计(SQLServer2000无分区概念,只能采用分月表的形式)
5、数据库链接的处理
6、日志和控制表的设计
7、ETL增量策略
8、维度数据的处理
9、原始业务数据的处理
10、事实表数据的处理
11、OLAP分区和增量处理
12、数据库性能优化

使用道具 举报

回复
论坛徽章:
181
慢羊羊
日期:2015-03-04 14:19:442015年新春福章
日期:2015-03-06 11:57:31
9#
 楼主| 发表于 2006-11-9 23:46 | 只看该作者
关于数据库的设计

数据库可以按照以下几种情况进行分库处理:
1、按照不同的业务数据归类进行分库
2、按照数据仓库的分层结构进行分库,如ODS数据库、事实数据库
3、按照数据的存储周期进行分类(历史数据和临时数据)

个人建议,采用按照分层结构进行分库,如
dataware_orginal      存储ODS数据,从业务系统抽取过来的数据
dataware_fact           存储事实表(聚合)数据
dataware_dimension 存储维度表数据

使用道具 举报

回复
论坛徽章:
181
慢羊羊
日期:2015-03-04 14:19:442015年新春福章
日期:2015-03-06 11:57:31
10#
 楼主| 发表于 2006-11-9 23:50 | 只看该作者
关于文件组的设计

数据库可以按照以下几种情况进行文件组设计(其实同上,关键如何分类更加合理):
1、按照业务数据来源分类
2、按照ETL处理过程分类
3、按照数据的存储周期分类(历史数据还是临时数据)
4、按照数据的物理存储类型分类(即索引还是数据)

个人建议,采用按照物理存储类型和数据存储周期进行分库,如
历史数据文件组
临时表数据文件组
索引文件组

使用道具 举报

回复

您需要登录后才可以回帖 登录 | 注册

本版积分规则 发表回复

TOP技术积分榜 社区积分榜 徽章 团队 统计 知识索引树 积分竞拍 文本模式 帮助
  ITPUB首页 | ITPUB论坛 | 数据库技术 | 企业信息化 | 开发技术 | 微软技术 | 软件工程与项目管理 | IBM技术园地 | 行业纵向讨论 | IT招聘 | IT文档
  ChinaUnix | ChinaUnix博客 | ChinaUnix论坛
CopyRight 1999-2011 itpub.net All Right Reserved. 北京盛拓优讯信息技术有限公司版权所有 联系我们 未成年人举报专区 
京ICP备16024965号-8  北京市公安局海淀分局网监中心备案编号:11010802021510 广播电视节目制作经营许可证:编号(京)字第1149号
  
快速回复 返回顶部 返回列表