Anda di halaman 1dari 41

1 Copyright 2013, Oracle and/or its affiliates. All rights reserved.

Dimensional Modeling in Oracle


SQL Developer
Data
Modeler
Philip Stoyanov
Senior Software Development Manager

2 Copyright 2013, Oracle and/or its affiliates. All rights reserved.


Legal
The following is intended to outline our general product direction. It is intended for
information purposes only, and may not be incorporated into any contract. It is not a
commitment to deliver any material, code, or functionality, and should not be relied
upon in making purchasing decisions. The development, release, and timing of any
features or functionality described for Oracles products remains at the sole
discretion of Oracle.

3 Copyright 2013, Oracle and/or its affiliates. All rights reserved.


Agenda

Dimensional model
Reporting
Dimensions in physical model for Oracle

4 Copyright 2013, Oracle and/or its affiliates. All rights reserved.


Models DB Site 1
Data Types Subject Subject
Area 1 Area n Oracle 9i
Model

Relational
Model 1
Process Model DB Site n
Data flow Oracle 12c
diagramming Logical
Dimensional
Model Models 1..n
DB Site 1
DB2/390 v.8

Relational
Subject
Subject Model n
Area n DB Site n
Area 1
MS SQLS 2005

5 Copyright 2013, Oracle and/or its affiliates. All rights reserved.


Relational model without relationships

Even if we add
foreign keys still
there are
dependencies
that remain
hidden

6 Copyright 2013, Oracle and/or its affiliates. All rights reserved.


Dimensional model can show more

Extends definitions
in Logical and
Relational models
additional 1:1 and
1:n dependencies in
the scope of one
table can be
described

7 Copyright 2013, Oracle and/or its affiliates. All rights reserved.


Can be mapped to Logical or Relational
model
Relational model direct
mappings to tables and views
Logical model used entities
need to be engineered to
relational model in order to
have mapping to specific tables

8 Copyright 2013, Oracle and/or its affiliates. All rights reserved.


Dimensional model elements

Dimension
Level
Hierarchy
Link
Cube
Measure
Slice subset of cube dimensions and measures

Oracle names (short, long, plural) can be defined for each element and exported to Oracle OLAP

9 Copyright 2013, Oracle and/or its affiliates. All rights reserved.


Dimension

Can be Regular or Time


Consists of levels and hierarchies
Concept of merging dimensions is
supported hierarchies can span
levels from more than one
dimension
Dimension has one base level that
defines dimensions grain

10 Copyright 2013, Oracle and/or its affiliates. All rights reserved.


Merging dimensions example

Level Sales
Territory Region
belongs to three
dimensions

11 Copyright 2013, Oracle and/or its affiliates. All rights reserved.


Level

Level is mapped to exactly one entity (table or view).


Several levels can be mapped to one entity
Can be Regular level or level that represents value
based (parent-child) hierarchy
Has a key defined over one or several attributes
Has descriptive attributes that map to exactly one
column from dimension table

12 Copyright 2013, Oracle and/or its affiliates. All rights reserved.


Level

Mapping of optional short description and long description


attributes can be defined and mapping of mandatory time
span and time end attributes should be defined for level
belonging to time dimension
Has calculated attributes expressions over dimension
table columns
Value based hierarchy is defined with level key and
parent key attributes
Member selection criteria can be defined

13 Copyright 2013, Oracle and/or its affiliates. All rights reserved.


Level - calculated attribute

14 Copyright 2013, Oracle and/or its affiliates. All rights reserved.


Hierarchy

Defines roll-up path and can connect levels belonging


to different dimensions (merging dimensions)
Hierarchies are built and modified automatically during
the process of connecting levels and dimension node
Three types of hierarchies Parent-Child (value based
hierarchy), Level based and Ragged
Joins are defined for levels mapped to different tables

15 Copyright 2013, Oracle and/or its affiliates. All rights reserved.


Hierarchy

Hierarchy is created when dimension shape is connected (using New Link)


to base level.

16 Copyright 2013, Oracle and/or its affiliates. All rights reserved.


Link

Used to define hierarchies and dimension usage. Child to parent attributes can be defined
when link connects levels defined on different entities

17 Copyright 2013, Oracle and/or its affiliates. All rights reserved.


Value based hierarchy

Level is used to define key, parent key and descriptive attributes

18 Copyright 2013, Oracle and/or its affiliates. All rights reserved.


Ragged hierarchy

Corresponds to skip level hierarchy in Oracle OLAP use New Ragged Hierarchy Link tool
in order to mark and represent a jump over level(s) dashed green link below

19 Copyright 2013, Oracle and/or its affiliates. All rights reserved.


Dimension usage
link between cube and dimension defines child to parent attributes (join of fact entity to base level of
dimension), whether its role playing dimension and other related properties
Separate dimension is created in Oracle OLAP for each role playing dimension

20 Copyright 2013, Oracle and/or its affiliates. All rights reserved.


Cube

Cube defined on two fact entities:


Defines fact entities and joins FactInternetSales and
between them FactResellerSales

Container for measures defined on


facts from fact entities
Defines dimensions usage and joins
to dimensions support for role
playing dimensions
Container for Slices based on cube Abbreviations:
A measure based on fact
definition FX measure based on formula
expression
R reference to dimension

21 Copyright 2013, Oracle and/or its affiliates. All rights reserved.


Cube - partitioning

Partitioning
dimension,
hierarchy, level
Settings for
composites

22 Copyright 2013, Oracle and/or its affiliates. All rights reserved.


Cube summary levels (pre-compute)

23 Copyright 2013, Oracle and/or its affiliates. All rights reserved.


Measure

Measure can be based on single fact (direct mapping to


column) or expression involving facts and other measures
Measure can be Full-Additive, Semi-Additive or None-
Additive
One (at least) or more aggregation functions can be
defined for Full-Additive and Semi-Additive measure.
Semi-Additive measure has a list of dimensions on which it
is valid

24 Copyright 2013, Oracle and/or its affiliates. All rights reserved.


Basic measure

25 Copyright 2013, Oracle and/or its affiliates. All rights reserved.


Calculated measure

26 Copyright 2013, Oracle and/or its affiliates. All rights reserved.


Reports

There are no standard reports for Dimensional model


Custom reports integrated in Search functionality can be created
two levels of details are supported for cubes and dimensions (in
Data Modeler 4.0)
Custom reports can be generated in HTML, PDF or Excel format;
the latter one can be used to change properties in Excel file and
then to import them back into model

27 Copyright 2013, Oracle and/or its affiliates. All rights reserved.


Custom report template

28 Copyright 2013, Oracle and/or its affiliates. All rights reserved.


Custom report dimensions with details for
hierarchies and levels

29 Copyright 2013, Oracle and/or its affiliates. All rights reserved.


Dimensional Model - usage

Communication with customers custom reports, detailed and


compact diagrams for compact diagram use Show Compact
model in context menu for dimensional model node in the browser
Can be exported to Oracle AW
Dimensions in Oracle physical model can be created using
Engineer to Oracle Model functionality

30 Copyright 2013, Oracle and/or its affiliates. All rights reserved.


Detailed diagram

31 Copyright 2013, Oracle and/or its affiliates. All rights reserved.


Compact diagram

32 Copyright 2013, Oracle and/or its affiliates. All rights reserved.


Dimensions in Oracle physical model

Used by database
engine for query rewrite
related to materialized
views
Can be imported from
database dictionary or
DDL script

33 Copyright 2013, Oracle and/or its affiliates. All rights reserved.


SQL Dimension

34 Copyright 2013, Oracle and/or its affiliates. All rights reserved.


Dimension physical model

Dimensions, levels and


hierarchies can be
created/edited manually
Can be used as starting
point to create new
Dimensional model

35 Copyright 2013, Oracle and/or its affiliates. All rights reserved.


Dimensional model engineer from physical
model

36 Copyright 2013, Oracle and/or its affiliates. All rights reserved.


Dimensional model based on Sales History
(SH) sample schema

37 Copyright 2013, Oracle and/or its affiliates. All rights reserved.


Example

Oracle SQL Developer Data Modeler 3.3 (4.0) is


distributed with sample design and complementary
description located in
datamodeler\datamodeler\samples\Dimensional_model
directory

38 Copyright 2013, Oracle and/or its affiliates. All rights reserved.


Learn More..
SQL Developer Data Modeler on OTN -
http://www.oracle.com/technetwork/developer-tools/datamodeler
SQL Developer Data Modeler forum
https://forums.oracle.com/community/developer/english/development_to
ols/application_development_in_pl_sql/sql_developer_data_modeler
Oracle Learning Library
http://apex.oracle.com/pls/apex/f?p=44785:2:0:FORCE_QUERY::2,R
IR,CIR:P2_TAGS:Data%20Modeler
Jeff Smith http://www.thatjeffsmith.com/
Ashley Chen http://oracletoolsgirl.blogspot.co.uk/
Kris Rice http://krisrice.blogspot.co.uk/

39 Copyright 2013, Oracle and/or its affiliates. All rights reserved.


40 Copyright 2013, Oracle and/or its affiliates. All rights reserved.
41 Copyright 2013, Oracle and/or its affiliates. All rights reserved.

Anda mungkin juga menyukai