0% found this document useful (0 votes)
5 views68 pages

Lecture 7-Data Warehousing-Data Mining

The document provides an overview of data warehousing concepts, including its definition, architecture, and importance in decision support and data mining. It highlights the evolution of data warehousing, the distinction between OLTP and data warehouses, and the need for data integration and quality. Additionally, it discusses the various components and processes involved in creating an effective data warehouse for organizational decision-making.

Uploaded by

dsamuel8448
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
5 views68 pages

Lecture 7-Data Warehousing-Data Mining

The document provides an overview of data warehousing concepts, including its definition, architecture, and importance in decision support and data mining. It highlights the evolution of data warehousing, the distinction between OLTP and data warehouses, and the need for data integration and quality. Additionally, it discusses the various components and processes involved in creating an effective data warehouse for organizational decision-making.

Uploaded by

dsamuel8448
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 68

DATA WAREHOUSING CONCEPTS

J. LIECH HENRY
Data Warehousing, Data Mining

Multimedia University of Kenya

[email protected]
Course Overview
❚The course:
what and how

❚0. Introduction
❚I. Data Warehousing
❚II. Decision Support
and OLAP
❚III. Data Mining
❚IV. Looking Ahead
❚Demos and Labs 2
0. Introduction
❚Data Warehousing,
OLAP and data mining:
what and why
(now)?
❚Relation to OLTP
❚A case study

❚demos, labs

3
A producer wants to know….
Which are our
lowest/highest margin
customers ?
Who are my customers
What is the most and what products
effective distribution are they buying?
channel?

What product prom- Which customers


-otions have the biggest are most likely to go
impact on revenue? to the competition ?
What impact will
new products/services
have on revenue
and margins? 4
Data, Data everywhere
yet ... ❚ I can’t find the data I need
❙ data is scattered over the
network
❙ many versions, subtle
differences
❚ I can’t get the data I need
❙ need an expert to get the data

❚ I can’t understand the data I


found
❙ available data poorly documented

❚ I can’t use the data I found


❙ results are unexpected
❙ data needs to be transformed
from one form to other 5
What is a Data Warehouse?

A single, complete and


consistent store of data
obtained from a variety
of different sources
made available to end
users in a what they
can understand and use
in a business context.

[Barry Devlin]
6
What are the users saying...
❚Data should be integrated
across the enterprise
❚Summary data has a real
value to the organization
❚Historical data holds the
key to understanding data
over time
❚What-if capabilities are
required

7
What is Data Warehousing?

A process of
Information transforming data into
information and
making it available to
users in a timely
enough manner to
make a difference

[Forrester Research, April


Data 1996]
8
Evolution

❚ 60’s: Batch reports


❙ hard to find and analyze information
❙ inflexible and expensive, reprogram every new
request
❚ 70’s: Terminal-based DSS and EIS (executive
information systems)
❙ still inflexible, not integrated with desktop tools
❚ 80’s: Desktop data access and analysis tools
❙ query tools, spreadsheets, GUIs
❙ easier to use, but only access operational databases
❚ 90’s: Data warehousing with integrated OLAP
engines and tools 9
Warehouses are Very Large
Databases
35%

30%

25%
Respondents

20%

15%

10%
Initial
5% Projected 2Q96
Source: META Group, Inc.
0%
5GB 10-19GB 50-99GB 250-499GB
5-9GB 20-49GB 100-249GB 500GB-1TB
10
Very Large Data Bases
❚ Terabytes -- 10^12 bytes:Walmart -- 24 Terabytes

❚ Petabytes -- 10^15 bytes:Geographic Information


Systems
❚ Exabytes -- 10^18 bytes: National Medical Records

❚ Zettabytes -- 10^21 Weather images


bytes:
Intelligence Agency
❚ Zottabytes -- 10^24 Videos
bytes:
11
Data Warehousing --
It is a process
❚Technique for assembling and
managing data from various
sources for the purpose of
answering business
questions. Thus making
decisions that were not
previous possible
❚A decision support database
maintained separately from
the organization’s operational
database 12
Data Warehouse
❚A data warehouse is a
❙subject-oriented
❙integrated time-
❙varying non-
❙volatile

collection of data that is used primarily in


organizational decision making.
-- Bill Inmon, Building the Data Warehouse 1996

13
Explorers, Farmers and Tourists

Tourists: Browse information


harvested by farmers

Farmers: Harvest information


from known access paths

Explorers: Seek out the unknown and


previously unsuspected rewards hiding in
the detailed data

14
Data Warehouse Architecture
Relational
Databases
Optimized Loader
Extraction
ERP
Systems Cleansing

Data Warehouse
Engine Analyze
Purchased Query
Data

Legacy
Data Metadata Repository
15
Data Warehouse for Decision
Support & OLAP
❚P
utting Information technology to help the
knowledge worker make faster and better
decisions
❙Which of my customers are most likely to go
to the competition?
❙What product promotions have the biggest
impact on revenue?
❙How did the share price of software
companies correlate with profits over last 10
years?
16
Decision Support
❚Used to manage and control business
❚Data is historical or point-in-time
❚Optimized for inquiry rather than update
❚Use of the system is loosely defined and
can be ad-hoc
❚Used by managers and end-users to
understand the business and make
judgements
17
Data Mining works with Warehouse
Data
❚Data Warehousing
provides the Enterprise
with a memory

❚Data Mining provides


the Enterprise with
intelligence
18
We want to know ...
❚ Given a database of 100,000 names, which persons are the
least likely to default on their credit cards?
❚ Which types of transactions are likely to be fraudulent
given the demographics and transactional history of a
particular customer?
❚ If I raise the price of my product by Rs. 2, what is the
effect on my ROI?
❚ If I offer only 2,500 airline miles as an incentive to
purchase rather than 5,000, how many lost responses will
result?
❚ If I emphasize ease-of-use of the product as opposed to its
technical capabilities, what will be the net effect on my
revenues?
❚ Which of my customers are likely to be the most loyal?

Data Mining helps extract such information


19
Application Areas

Industry Application
Finance Credit Card Analysis
Insurance Claims, Fraud Analysis
Telecommunication Call record analysis
Transport Logistics management
Consumer goods promotion analysis
Data Service providers Value added data
Utilities Power usage analysis

20
Why Separate Data Warehouse?
❚ Performance
❙ Op dbs designed & tuned for known txs & workloads.
❙ Complex OLAP queries would degrade perf. for op txs.
❙ Special data organization, access & implementation
methods needed for multidimensional views & queries.

❚ Function
❙ Missing data: Decision support requires historical data, which
op dbs do not typically maintain.
❙ Data consolidation: Decision support requires consolidation
(aggregation, summarization) of data from many
heterogeneous sources: op dbs, external sources.
❙ Data quality: Different sources typically use inconsistent data
representations, codes, and formats which have to be 21
reconciled.
Application-Orientation vs.
Subject-Orientation
Application-Orientation Subject-Orientation

Operational Data
Database Warehouse

Credit
Loans Card Customer

Vendor
Trust Product

Savings Activity
22
OLTP vs. Data Warehouse

❚OLTP systems are tuned for known


transactions and workloads while
workload is not known a priori in a data
warehouse
❚Special data organization, access methods
and implementation methods are needed
to support data warehouse queries
(typically multidimensional queries)
❙e.g., average amount spent on phone calls
between 9AM-5PM in Pune during the month
of December
23
OLTP vs Data Warehouse

❚OLTP ❚Warehouse (DSS)


❙Application ❙Subject Oriented
Oriented ❙Used to analyze
❙Used to run business
business ❙Summarized and
❙Detailed data refined
❙Current up to date ❙Snapshot data
❙Isolated Data ❙Integrated Data
❙Repetitive access ❙Ad-hoc access
❙Clerical User ❙Knowledge User
(Manager)
24
OLTP vs Data Warehouse

❚ OLTP ❚ Data Warehouse


❙ Performance Sensitive ❙ Performance relaxed
❙ Few Records accessed at ❙ Large volumes accessed
a time (tens) at a time(millions)
❙ Mostly Read (Batch
❙ Read/Update Access Update)
❙ Redundancy present
❙ No data redundancy ❙ Database Size
❙ Database Size 100MB 100 GB - few terabytes
-100 GB

25
OLTP vs Data Warehouse

❚OLTP ❚Data Warehouse


❙Transaction ❙Query throughput is
throughput is the the performance
performance metric metric
❙Thousands of users ❙Hundreds of users
❙Managed in entirety ❙Managed by
subsets

26
To summarize ...
❚OLTP Systems are
used to “run” a
business

❚The Data
Warehouse helps
to “optimize” the
business
27
Why Now?

❚Data is being produced


❚ERP provides clean data
❚The computing power is available
❚The computing power is affordable
❚The competitive pressures are strong
❚Commercial products are available

28
I. Data Warehouses:
Architecture, Design & Construction
❚DW Architecture
❚Loading, refreshing
❚Structuring/Modeling
❚DWs and Data Marts
❚Query Processing

❚demos, labs

29
Data Warehouse Architecture
Relational
Databases
Optimized Loader

ERP Extraction
Systems Cleansing

Data Warehouse
Engine Analyze
Purchased Query
Data

Legacy
Data Metadata Repository
30
Components of the Warehouse

❚Data Extraction and Loading


❚The Warehouse
❚Analyze and Query -- OLAP Tools
❚Metadata

❚Data Mining tools

31
Loading the Warehouse

Cleaning the data


before it is loaded
Data Quality - The Reality

❚Tempting to think creating a data


warehouse is simply extracting
operational data and entering into a
data warehouse

❚Nothing could be farther from the


truth
❚Warehouse data comes from
disparate questionable sources 33
Data Quality - The Reality

❚Legacy systems no longer documented


❚Outside sources with questionable quality
procedures
❚P
roduction systems with no built in
integrity checks and no integration
❙Operational systems are usually designed to
solve a specific business problem and are
rarely developed to a a corporate plan
❘“And get it done quickly, we do not have time to
worry about corporate standards...”
34
Data Integration Across Sources

Savings Loans Trust Credit card

Same data Different data Data found here Different keys


different name Same name nowhere else same data

35
Data Integrity Problems

❚ Same person, different spellings


❙Agarwal, Agrawal, Aggarwal etc...
❚ Multiple ways to denote company name
❙Persistent Systems, PSPL, Persistent Pvt.
LTD.
❚ Use of different names
❙mumbai, bombay
❚ Different account numbers generated by
different applications for the same customer
❚ Required fields left blank
❚ Invalid product codes collected at point of sale
❙manual entry leads to mistakes
51
❙“in case of a problem use 9999999”
Data Transformation Terms

❚Extracting ❚Enrichment
❚Conditioning ❚Scoring
❚Scrubbing ❚Loading
❚Merging ❚Validating
❚Householding ❚Delta Updating

37
Data Transformation Terms

❚Extracting
❙Capture of data from operational source in
“as is” status
❙Sources for data generally in legacy
mainframes in VSAM, IMS, IDMS, DB2; more
data today in relational databases on Unix
❚Conditioning
❙The conversion of data types from the source
to the target data store (warehouse) --
always a relational database
38
Data Transformation Terms

❚Householding
❙Identifying all members of a household
(living at the same address)
❙Ensures only one mail is sent to a
household
❙Can result in substantial savings: 1 lakh
catalogues at Rs. 50 each costs Rs. 50
lakhs. A 2% savings would save Rs. 1
lakh.

39
Data Transformation Terms

❚Enrichment
❙Bring data from external sources to
augment/enrich operational data. Data
sources include Dunn and Bradstreet, A.
C. Nielsen, CMIE, IMRA etc...
❚Scoring
❙computation of a probability of an
event. e.g..., chance that a customer
will defect to AT&T from MCI, chance
that a customer is likely to buy a new
product
40
Structuring/Modeling Issues
Data -- Heart of the Data
Warehouse
❚Heart of the data warehouse is the
data itself!
❚Single version of the truth
❚Corporate memory
❚Data is organized in a way that
represents business -- subject
orientation

42
Data Warehouse Structure

❚Subject Orientation -- customer,


product, policy, account etc... A
subject may be implemented as a
set of related tables. E.g.,
customer may be five tables

43
Data Warehouse Structure
❙base customer (1985-87)
❘custid, from date, to date, name, phone, dob
Time is ❙base customer (1988-90)
part of ❘custid, from date, to date, name, credit rating,
key of employer
each table
❙customer activity (1986-89) -- monthly
summary
❙customer activity detail (1987-89)
❘custid, activity date, amount, clerk id, order no
❙customer activity detail (1990-91)
❘custid, activity date, amount, line item no, order no

44
Data Granularity in Warehouse

❚Summarized data stored


❙reduce storage costs
❙reduce cpu usage
❙increases performance since smaller
number of records to be processed
❙design around traditional high level
reporting needs
❙tradeoff with volume of data to be
stored and detailed usage of data
45
Granularity in Warehouse

❚Can not answer some questions with


summarized data
❙Did Anand call Seshadri last month? Not
possible to answer if total duration of
calls by Anand over a month is only
maintained and individual call details
are not.
❚Detailed data too voluminous

46
Granularity in Warehouse

❚Tradeoff is to have dual level of


granularity
❙Store summary data on disks
❘95% of DSS processing done against this
data
❙Store detail on tapes
❘5% of DSS processing against this data

47
Vertical Partitioning

Acct. Interest
Name Balance Date Opened Address
No Rate

Frequently
accessed Rarely
accessed
Acct. Acct. Interest
Balance Name Date Opened Address
No No Rate

Smaller table
and so less I/O
48
Schema Design

❚Database organization
❙must look like business
❙must be recognizable by business user
❙approachable by business user
❙Must be simple
❚Schema Types
❙Star Schema
❙Fact Constellation Schema
❙Snowflake schema
49
Dimension Tables

❚Dimension tables
❙Define business in terms already
familiar to users
❙Wide rows with lots of descriptive text
❙Small tables (about a million rows)
❙Joined to fact table by a foreign key
❙heavily indexed
❙typical dimensions
❘time periods, geographic region (markets,
cities), products, customers, salesperson,
etc. 50
Star Schema

❚A single fact table and for each


dimension one dimension table
❚Does not capture hierarchies directly
T date, custno, prodno, cityname, ...
p
i r
m o
e f d
a
c c c
u t i
s t
t y 51
Snowflake schema

❚Represent dimensional hierarchy directly


by normalizing tables.
❚Easy to maintain and saves storage
T date, custno, prodno, cityname, ...
p
i r
m o
e f d
a
c c c r
u t i e
s g
t i
t y o
52
n
De-normalization

❚Normalization in a data warehouse


may lead to lots of small tables
❚Can lead to excessive I/O’s since
many tables have to be accessed
❚De-normalization is the answer
especially since updates are rare

53
Partitioning
❚Breaking data into several
physical units that can be
handled separately
❚Not a question of whether
to do it in data
warehouses but how to do
it
❚Granularity and
partitioning are key to
effective implementation
of a warehouse
54
Why Partition?

❚Flexibility in managing data


❚Smaller physical units allow
❙easy restructuring
❙free indexing
❙sequential scans if needed
❙easy reorganization
❙easy recovery
❙easy monitoring

55
Criterion for Partitioning

❚Typically partitioned by
❙date
❙line of business
❙geography
❙organizational unit
❙any combination of above

56
Where to Partition?

❚Application level or DBMS level


❚Makes sense to partition at
application level
❙Allows different definition for each year
❘Important since warehouse spans many
years and as business evolves definition
changes
❙Allows data to be moved between
processing complexes easily

57
Data Warehouse vs. Data Marts

What comes first


From the Data Warehouse to Data
Marts
Information

Individually Less
Structured

Departmentally History
Structured Normalized
Detailed

Organizationally More
Structured Data Warehouse

Data
59
Data Warehouse and Data Marts
OLAP
Data Mart
Lightly summarized
Departmentally structured

Organizationally structured
Atomic
Detailed Data Warehouse Data

60
Characteristics of the
Departmental Data Mart
❚OLAP
❚Small
❚Flexible
❚Customized by
Department
❚Source is
departmentally
structured data
warehouse

61
Techniques for Creating
Departmental Data Mart
❚O
LAP
Sales Finance Mktg. ❚Subset
❚Summarized
❚Superset
❚Indexed
❚Arrayed

62
Data Mart Centric

Data Sources

Data Marts

Data Warehouse

63
Problems with Data Mart Centric
Solution

If you end up creating multiple warehouses,


integrating them is a problem

64
True Warehouse

Data Sources

Data Warehouse

Data Marts

65
Warehouse Products
❚Computer Associates -- CA-Ingres
❚Hewlett-Packard -- Allbase/SQL
❚Informix -- Informix, Informix XPS
❚Microsoft -- SQL Server
❚Oracle -- Oracle7, Oracle Parallel Server
❚Red Brick -- Red Brick Warehouse
❚SAS Institute -- SAS
❚Software AG -- ADABAS
❚Sybase -- SQL Server, IQ, MPP
66
Warehouse Server Products

❚O
racle 8
❚Informix
❙Online Dynamic Server
❙S
X
P --Extended Parallel Server
❙Universal Server for object relational
applications
❚Sybase
❙Adaptive Server 11.5
❙Sybase MPP
❙Sybase IQ
67
Warehouse Server Products

❚Red Brick Warehouse


❚Tandem Nonstop
❚IBM
❙DB2 MVS
❙Universal Server
❙DB2 400
❚Teradata

68

You might also like