Professional Documents
Culture Documents
An Introduction To Dimensional Data Warehousing Design
An Introduction To Dimensional Data Warehousing Design
Warehouse Design
Presented by
Joseph J. Sarna Jr.
JJS Systems, LLC
Relational Normal Form
Categories
PK CategoryID Orders
Order Details CustomerCustomerDemo
I1 CategoryName Products PK OrderID Customers
Description PK,FK1,I2,I1 OrderID PK,FK2 CustomerID
Picture PK ProductID FK1,I1,I2 CustomerID PK CustomerID
PK,FK2,I4,I3 ProductID PK,FK1 CustomerTypeID
FK2,I4,I3 EmployeeID
I3 ProductName I5 OrderDate I2 CompanyName
UnitPrice
FK2,I4,I5 SupplierID RequiredDate ContactName
Quantity
FK1,I2,I1 CategoryID I6 ShippedDate ContactTitle
Discount
QuantityPerUnit FK3,I7 ShipVia Address
UnitPrice Freight I1 City
UnitsInStock ShipName I4 Region
UnitsOnOrder ShipAddress I3 PostalCode
ReorderLevel ShipCity Country
Suppliers Discontinued ShipRegion Phone
I8 ShipPostalCode Fax
PK SupplierID
ShipCountry
I1 CompanyName
ContactName
CustomerDemographics
ContactTitle
Address PK CustomerTypeID
City
Region CustomerDesc
I2 PostalCode Shippers
Country
Phone PK ShipperID
Fax
HomePage CompanyName
Phone
Why Dimensional Data Warehouses?
– Be competitive
Data Distribution
Acquisition, Staging, Cleaning,
Transformation
• Detail Level
– Dimensional Normal form
– Value and feasibility
• Analytical Level
– Structured for the required analyses
• Summary Level
– Summaries for user requirements
– Better response time
Dimensional Normal Form
PK EmployeeKey
• Fact Tables
– contain related measures
– Usually the largest tables
– Usually appended to
– Can contain detail or summary data
– Measures are usually additive
• Dimension Tables
– Contain descriptors
– Utilize business terminology
– Textual and discrete data
– Attributes through which the table measures are analyzed
Northwind Database – Star Schema – Orders
dimDate
PK DateKey
DayDate
DayDate_YYYYMMDD
DayOfWeekName
DayOfWeekNameAbbrv
DayNumberInWeek dimEmployees
DayNumberInMonth
DayNumberInQuarte PK EmployeeKey
DayNumberInYear
WeekDayIndicator EmployeeID
WeekEndIndicator LastName
Week_YYYYWW FirstName
WeekNumberInYear Title
Month_YYYYMM TitleOfCourtesy
MonthName BirthDate
MonthNameAbbrv HireDate
MonthNumberInYear Address
Quarter_YYYYQ City
QuarterName Region
QuarterNameAbrv PostalCode
QuarterNumberInYear Country
dimOrderDetails Year HomePhone
Extension
PK ProductKey Photo
Notes
OrderID ReportsTo
UnitPrice PhotoPath
Quantity fctOrders
TerritoryID
Discount PK OrderKey TerritoryDescription
ExtendedPrice RegionID
ProductID FK3 ProductKey RegionDescription
ProductName FK2 EmployeeKey
QuantityPerUnit FK1 CustomerKey
UnitPrice FK4 ShipperKey
UnitsInStock FK6 OrderDateKey
UnitsOnOrder FK5 RequiredDateKey
ReorderLevel FK7 ShippedDateKey
Discontinued OrderID
CategoryID ShipVia
CategoryName Freight
Description ShipName dimCustomers
SupplierID ShipAddress
CompanyName PK CustomerKey
ShipCity
ContactName ShipRegion
ContactTitle CustomerID
ShipPostalCode
Address CompanyName
ShipCountry
City ContactName
Region ContactTitle
PostalCode Address
Country City
Phone Region
Fax PostalCode
HomePage Country
dimShippers
Phone
PK ShipperKey Fax
CustomerTypeID
ShipperID CustomerDesc
CompanyName
Phone
Resources
• Books
– The Data Warehouse Toolkit, Ralph Kimball
– The Data Warehouse Lifecycle Toolkit, Ralph Kimball, et al
– Data Warehouse Design Solutions, Adamson / Venerable
• Websites
– http://www.ralphkimball.com/
– http://www.atre.com
– http://www.microsoft.com/sql/evaluation/overview/
dataware.asp