SEM 6 › Data Mining › Week 07
Data Mining · Week 07

Design of a Data Warehouse

Benefits, the four design views, top-down vs bottom-up, the 4-step design process, three-tier architecture, the metadata repository, and ROLAP / MOLAP / HOLAP servers.

ITE34321 video · 11 min📄 week 7_5.pdf

▶Lecture videos

Click any timestamp — here or inside the notes — to jump the video to that moment. Your position is remembered.

1Why build a data warehouse?

To build an effective warehouse you need a clear understanding and analysis of business needs. The four benefits:

Benefit How the warehouse delivers it
Competitive advantage Presents relevant information to measure performance and make critical adjustments to beat competitors
Business productivity Quickly and efficiently gathers information that accurately describes the organisation
Customer relationship management Gives a consistent view of customers and items across all lines of business, departments and markets
Cost reduction Tracks trends, patterns and exceptions over long periods, consistently and reliably

2The four views of warehouse design

The building analogy

Building a large information system is like constructing a large building: the owner, architect and builder each have a different view. A warehouse has four views:

View Whose perspective / what it shows
Top-down view Selects the relevant information the warehouse needs, matching current and future business needs
Data source view The information captured, stored and managed by operational systems, at various levels of detail. Modelled with ER models or CASE tools
Data warehouse view The fact and dimension tables stored inside the warehouse, including pre-calculated totals and counts plus source, date and time of origin for historical context
Business query view The data as seen by the end user
Memory hook: "T-S-W-B"

Top-down → what we need · Source → what we have · Warehouse → what we store · Business query → what users see.

3Design approaches & methodology

Top-down, bottom-up or combined

Approach Starts with Best when
Top-down Overall design and planning Technology is mature and well known, and the business problems are clear and well understood
Bottom-up Experiments and prototypes Early stage of business modelling and technology. Lets the organisation move forward at much less expense and evaluate benefits before committing
Combined Both Gets the planned, strategic nature of top-down plus the rapid implementation and opportunistic use of bottom-up

Software-engineering steps

PlanningRequirements studyProblem analysisWarehouse designData integration & testingDeployment

There are two development methodologies:

  • Waterfall: structured, systematic analysis at each step before moving to the next, falling from stage to stage.
  • Spiral: rapid generation of increasingly functional systems with short intervals between releases.

4The 4-step warehouse design process

  1. Choose a business process to model, e.g. orders, invoices, shipments, inventory, account administration, sales, general ledger.
    • The process is organisational with many complex object collections → use a data warehouse model.
    • The process is departmental, focused on one kind of business process → use a data mart model.
  2. Choose the grain: the fundamental, atomic level of data in the fact table, e.g. individual transactions or individual daily snapshots.
  3. Choose the dimensions for each fact-table record, e.g. time, item, customer, supplier, warehouse, transaction type, status.
  4. Choose the measures for each fact-table record, usually numeric additive quantities such as dollars_sold, units_sold.
🧪 Try it — Design-a-warehouse wizard

Follow the 4 steps. The fact table and DMQL update as you choose.

3. Dimensions:
4. Measures:
Exam focus

"State the steps of the warehouse design process" means process → grain → dimensions → measures, each with an example. Also be able to explain top-down vs bottom-up.

5Three-tier data warehouse architecture

 TOP TIER     ┌─────────────────────────────────────────────┐
 Front-end    │ Query/report tools · Analysis · Data mining │
 client       └──────────────────────┬──────────────────────┘
 MIDDLE TIER  ┌──────────────────────┴──────────────────────┐
 OLAP server  │        ROLAP  or  MOLAP  OLAP server         │
              └──────────────────────┬──────────────────────┘
 BOTTOM TIER  ┌──────────────────────┴──────────┬───────────┐
 Warehouse    │ Data warehouse (relational DB)  │ Metadata  │
 DB server    │       + Data marts              │ repository│
              └──────────────────────┬──────────┴───────────┘
        Extract · Clean · Transform · Load · Refresh
              Operational databases    External sources
Tier What it is Key points
Bottom Warehouse database server, almost always a relational DB Back-end tools extract, clean, transform, load and refresh data from operational and external sources. Holds the metadata repository
Middle OLAP server Either ROLAP (extended relational DBMS that maps multidimensional operations to relational ones) or MOLAP (special-purpose server that implements multidimensional data directly)
Top Front-end client layer Query and reporting tools, analysis tools, data mining tools

From the architecture point of view there are three warehouse models:

  • Enterprise warehouse: covers the whole organisation.
  • Data mart: a departmental subset.
  • Virtual warehouse: a set of views over operational databases; easy to build but needs spare capacity on the operational servers.

6The metadata repository

Metadata = data about data. In a warehouse, metadata define the warehouse objects. The repository sits in the bottom tier.

  • Metadata are created for data names and definitions.
  • Extra metadata record timestamps of extracted data, the source of the information, and missing fields added by cleaning or integration.

What the repository should contain (six things):

# Contents Includes
1 Structure of the warehouse Schema, views, dimensions, hierarchies, derived data definitions, data mart locations and contents
2 Operational metadata Data lineage (history of migrated data and its transformations), currency of data (active, archived or purged), monitoring (usage statistics, error reports, audit trails)
3 Summarisation algorithms Measure and dimension definitions, granularity, partitions, subject areas, aggregation, predefined queries and reports
4 Mapping from operational environment to warehouse Source DBs, gateways, partitions, extraction/cleaning/transformation rules, refresh and purge rules, security (authorisation, access control)
5 System performance data Indices and profiles for fast access, plus timing and scheduling of refresh, update and replication
6 Business metadata Business terms and definitions, data ownership, charging policies
Memory hook: "SOS-MPB"

Structure · Operational · Summarisation · Mapping · Performance · Business

7OLAP server models: ROLAP, MOLAP, HOLAP

ROLAP (Relational OLAP) MOLAP (Multidimensional OLAP) HOLAP (Hybrid OLAP)
Storage Relational / extended-relational DBMS plus OLAP middleware Array-based multidimensional storage engines: data cube arrays Detail data in relational DB, aggregations in a MOLAP store
Strength Greater scalability Fast indexing to pre-computed summarised data Both: scalability of ROLAP + fast computation of MOLAP
Notes Optimisation for each DBMS back end; aggregation navigation logic Two-level storage: dense sub-cubes as arrays, sparse sub-cubes compressed —
Example product MicroStrategy DSS server (e.g. Essbase) Microsoft SQL Server 2000

ROLAP vs MOLAP in one line each

  • ROLAP: data stays in tables, so it scales to huge data but answers more slowly.
  • MOLAP: data sits in cube arrays, so it is very fast but less scalable and can waste space on sparse data.

Dense vs sparse

A dense sub-cube has most cells filled, so arrays are efficient. A sparse one has mostly empty cells, so MOLAP compresses it.

8Weka 1.3 — Exploring datasets

The Weka video shows what's inside a dataset:

  • ARFF format (Attribute-Relation File Format): a header with @relation, @attribute lines (name and type), then @data with one instance per line.
  • Nominal attributes take values from a fixed set (e.g. outlook = sunny/overcast/rainy). Numeric attributes are numbers (e.g. temperature).
  • The class attribute (usually the last one) is what we want to predict (e.g. play = yes/no in the weather dataset).
@relation weather
@attribute outlook {sunny, overcast, rainy}
@attribute temperature numeric
@attribute humidity numeric
@attribute windy {TRUE, FALSE}
@attribute play {yes, no}
@data
sunny,85,85,FALSE,no
overcast,83,86,FALSE,yes

9Quick revision sheet

Concept Remember it as
Benefits Competitive advantage · productivity · CRM · cost reduction
4 views Top-down · Data source · Data warehouse · Business query
Top-down vs bottom-up Plan first (mature tech, clear problems) vs prototype first (early stage, cheaper)
Waterfall vs spiral Step-by-step vs rapid increasing releases
4 design steps Business process → Grain → Dimensions → Measures
3 tiers Bottom: relational warehouse server + metadata · Middle: OLAP server · Top: client tools
3 models Enterprise warehouse · Data mart · Virtual warehouse
Metadata Data about data; 6 contents (SOS-MPB)
ROLAP Relational, scalable (MicroStrategy)
MOLAP Arrays, fast, dense/sparse two-level storage
HOLAP Detail in ROLAP, aggregates in MOLAP (MS SQL Server 2000)

?Self-check quiz

10 questions on this week. Answer them all, then press Check my answers. Your best and latest scores are saved and shown on the subject page.