【文章內(nèi)容簡(jiǎn)介】
(8) 性別組 (2) 季度(40) 區(qū)域 (45) 產(chǎn)品組 (48) 月 (120) 城市 (280) 產(chǎn)品 (240) 區(qū) (880) 商店 (2022) 指標(biāo)和事實(shí) : 預(yù)測(cè)銷售量、實(shí)際銷售量、預(yù)測(cè)偏差 信息包: 銷售分析 維度 類別 多維數(shù)據(jù)模型 ? 數(shù)據(jù)倉(cāng)庫(kù)基于多維數(shù)據(jù)模型。 ? 該模型將數(shù)據(jù)看作數(shù)據(jù)立方體 (data cube)形式,允許以多維對(duì)數(shù)據(jù)建模和觀察。它由維和事實(shí)定義。維是關(guān)于一個(gè)組織想要記錄的透視或?qū)嶓w。每一個(gè)維都有一個(gè)進(jìn)一步描述維的表相關(guān)聯(lián),即維表。 以三維角度觀察銷售數(shù)據(jù) 數(shù)據(jù)立方體 以四維角度觀察銷售數(shù)據(jù) 4D立方體看成 3D 立方體的序列,依此類推 數(shù)據(jù)模型 (邏輯模型) ? 最流行的數(shù)據(jù)倉(cāng)庫(kù)數(shù)據(jù)模型就是多維數(shù)據(jù)模型,這種模型可以以星型模式、雪花模式或事實(shí)星座模式存在。 ? 數(shù)據(jù)倉(cāng)庫(kù)通常使用事實(shí)星座模式 ,因?yàn)樗軐?duì)多個(gè)相關(guān)的主題建模。對(duì)于數(shù)據(jù)集市,流行星型或雪花模式,因?yàn)樗鼈兌歼m合對(duì)單個(gè)主題建模。 ? 多維數(shù)據(jù)模型圍繞中心主題組織。該主題用事實(shí)表表示。事實(shí)表:用來(lái)存儲(chǔ)事實(shí)的度量值和各個(gè)維的碼值,維表用來(lái)存放維的元數(shù)據(jù)(維的層次、成員類別等描述信息)。 Time_id Sales Table Discount% Dollars Units Fact Table Market_id Product_id Scenario Product_id Product Table Size Brand Product_Desc Dimension Table Time_id Year Quarter Period_Desc Period Table Dimension Table Scenario Table Actual Profit Scenario Dimension Table Market_id Market Table Region District Market_Desc Dimension Table 星型模型 (Star Schema) Budget 雪花模式 (snowflake schema) ? 雪花模式是星型模式的變種,其中某些維表是規(guī)范化的 ,因而把數(shù)據(jù)進(jìn)一步分解到附加的表中。 ? 雪花模式和星型模式的主要不同在于雪花模式的維表可能是規(guī)范化形式,以便減少冗余。 ? 由于執(zhí)行查詢需要更多的連接操作,雪花模型可能降低瀏覽的性能。 事實(shí)星座 ? 復(fù)雜的應(yīng)用可能需要多個(gè)事實(shí)表共享維表,這種模式可以看作星型模式集,因此稱為星系模式 (galaxy schema),或事實(shí)星座 (fact constellation) 。 I B M B u s i n e s s I n t e l l i g e n c e S o l u t i o n | 2 0 0 4 169。 2 0 0 4 I B M Co r p o r a t i o n? I B M l o g o m u st n o t b e m o ve d , a d d e d t o , o r a l t e re d i na n y w a y .? Ba ck g ro u n d sh o u l dn o t b e m o d i f i e d .? T i t l e / su b t i t l e / co n f i d e n t i a l i t y l i n e : 1 0 p t Ar i a l R e g u l a r, w h i t eM a xi m u m l e n g t h : 1 l i n eI n f o rm a t i o n se p a r a t e d b y v e rt i ca l st ro ke s,w i t h t w o sp a ce s o n e i t h e r si d e? Sl i d e h e a d i n g :2 8 p t Ar i a l R e g u l a r, b l u e R 1 2 0 | G 1 3 7 | B2 5 1 M a xi m u m l e n g t h : 2 l i n e s? Sl i d e b o d y :1 8 p t Ar i a l R e g u l a r, b l a ckSq u a r e b u l l e t co l o r:t e a l R 0 4 5 | G 1 8 2 | B1 7 9R e co m m e n d e d m a xi m u m t e xt l e n g t h : 5 p ri n ci p a l p o i n t s? G ro u p n a m e :1 4 p t Ar i a l R e g u l a r, w h i t eM a xi m u m l e n g t h : 1 l i n e? C o p y ri g h t : 1 0 p t Ar i a lR e g u l a r, w h i t eO p t i o n a l sl i d e n u m b e r: 1 0 p t Ar i a l Bo l d , w h i t eT e m pl a t e re l e a s e : O c t 0 2Fo r t he l a t e s t , go t o ht t p : / / w 3 . i bm . c om/ i bm/ pre s e nt a t i on sI n d i ca t i o n s i n g rE SE n = L i v e co n t e n t I n d i ca t i o n s i n w h i t e = Ed i t i n m a st e rI n d i ca t i o n s i n b l u e = L o ck e d e l e m e n t sI n d i ca t i o n s i n b l a ck = O p t i o n a l e l e m e n t sI B M S of t w ar e G r oup | D B 2 I nf or m at i on M anagem ent S of t w ar eI B M DB2 I n f o r m a t i o n M a n a g e m e n t S o f t wa r e | 2 0 0 4 169。 200 4 I B M Co r p o r a t i o n電 信數(shù)據(jù)倉(cāng)庫(kù)模型( T D W M )相關(guān)方位置合約產(chǎn)品條件資源事件財(cái)務(wù)交易交互營(yíng)銷活動(dòng)監(jiān)控單元渠道分群數(shù)據(jù)挖掘查詢語(yǔ)言 ? 數(shù)據(jù)挖掘查詢語(yǔ)言 DMQL( data mining query language)是一種基于 SQL 的數(shù)據(jù)挖掘查詢語(yǔ)言 。 DMQL 包括定義數(shù)據(jù)倉(cāng)庫(kù)、數(shù)據(jù)集市、挖掘概念 /類描述、關(guān)聯(lián)和分類的語(yǔ)言原語(yǔ)。 ? 數(shù)據(jù)倉(cāng)庫(kù)和數(shù)據(jù)集市可以使用兩種原語(yǔ)定義:一種是立方體定義,一種是維定義 。 ? 立方體定義語(yǔ)句具有如下語(yǔ)法形式 : define cube cube_name [dimension_list]: measure_list ? 維定義語(yǔ)句具有如下語(yǔ)法形式: define dimension dimension_name as (attribute_or_subdimension_list) 定義星型、雪花和事實(shí)星座模式 例 1 數(shù)據(jù)立方體 sales 的 time, item 和 location 維可以與數(shù)據(jù)立方體 shipping 共享在定義數(shù)據(jù)立方體 shipping 語(yǔ)句之下,用 “ define dimension time as time in cube sales” 說(shuō)明。 例 2 度量的計(jì)算 ? 數(shù)據(jù)立方體度量 ( measure )是一個(gè)數(shù)值函數(shù),該函數(shù)可以對(duì)數(shù)據(jù)立方體的每一個(gè)點(diǎn)求值。 ? 大部分度量可以根據(jù)其所用的聚集函數(shù)分成 分布的和 代數(shù)的: ? 一個(gè)度量是分布的,如果它可以用分布聚集函數(shù) count( ),sum(), min(