Data Warehouse Project

Valerii Klymchuk
Valerii KlymchukData Scientist
Database Systems
Introduction to Databases and Data Warehouses
(Solutions to end-of-chapter exercises E8.1, E8.2, E8.3)
E8.1 ZAGI Retail Company
Consider the following, slightly modified, ZAGI Retail Company
scenario. The ZAGI Retail Company wants to create analytical database
to analyze sales.
The three available data sources are:
• Source 1 The ZAGI Retail Company Sales Department Database, as
shown below)
• Source 2 The ZAGI Retail Company Facilities Department Database
shown below
• Source 3 A Customer Demographic Data external table shown below.
Source 1: ZAGI Sales Department
Source 2: ZAGI Facilities Department
Source 3: Customer Demographic external
table
E8.1 ZAGI Retail Company data warehouse
The data warehouse has to enable an analysis of sales dollar amounts and
quantities by
• date, including: full date, day of week, day of month, month quarter, year
• time
• product, including: product name and price, product category, product
vendor
• customer, including: customer name, zip, gender, marital status, education
level, credit score
• store, including: individual store, store size and store zip, store checkout
system, store layout, store region.
ZAGI Sales Dimensional DW model
(star schema)
INSERT INTO Statements
INSERT INTO ZAGI_Dimensional.CALENDAR_D (FullDate, DayOfWeek, DayOfMonth, Month, Qtr,
Year ) SELECT DISTINCT TDate as FullDate, DAYOFWEEK(tdate) AS DayOfWeek,
dayofmonth(tdate) AS DayOfMonth, month(tdate) AS Month, quarter(tdate) AS Qtr, year(tdate) AS
Year FROM SALESTRANSACTION;
INSERT INTO ZAGI_Dimensional.PRODUCT_D (ProductID, ProductName, ProductPrice,
ProductVendorName, ProductCategoryName ) SELECT p.ProductID as ProductID,
p.ProductName, p.ProductPrice, v.VendorName AS ProductVendorName, c.CategoryName AS
ProductCategoryName FROM PRODUCT p, VENDOR v, CATEGORY c WHERE p.VendorID =
v.VendorID AND p.CategoryID = c.CategoryID GROUP BY p.ProductID;
INSERT INTO ZAGI_Dimensional.STORE_D (StoreID, StoreZip, StoreRegionName, StoreSize,
StoreCSystem, StoreLayout ) SELECT s.StoreID as StoreId, s.StoreZip AS StoreZip, r.RegionName
AS StoreRegionName, s1.StoreSize AS StoreSize, cs.CSystem AS StoreCSystem, l.Layout AS
StoreLayout FROM ZAGI_Sales_Dep.STORE s, ZAGI_Sales_Dep.REGION r,
ZAGI_Facilities_Dep.STORE1 s1, ZAGI_Facilities_Dep.CHECKOUTSYSTEM cs,
ZAGI_Facilities_Dep.LAYOUT l WHERE r.RegionID = s.RegionID AND s.StoreID=s1.StoreID AND
s1.CSID = cs.CSID AND s1.LTID = l.LayoutID GROUP BY s.StoreID;
INSERT INTO ZAGI_Dimensional.CUSTOMER_D(CustomerID, CustomerName, CustomerZip,
CustomerGender, CustomerMaritalStatus, CustomerEducationLevel, CustomerCreditScore )SELECT
t1.customerid as CustomerId, t1.customername AS CustomerName, t1.customerzip AS CustomerZip,
t2.gender AS CustomerGender, t2.maritalstatus AS CustomerMaritalStatus, t2.educationlevel AS
CustomerEducationLevel, t2.creditscore AS CustomerCreditScore FROM
ZAGI_Sales_Dep.CUSTOMER AS t1, ZAGI_Customer_Table.CUSTOMER_TABLE AS t2 WHERE
t1.CustomerID = t2.CustomerID;
CREATE VIEW `SALES_FACT_VIEW` AS SELECT st.TDate, st.StoreID, sv.ProductID,
st.CustomerID, sv.TID AS TID, st.TTime AS TimeOfDay, p.ProductPrice*sv.NoOfItems AS DollarsSold,
sv.NoOfItems AS UnitsSold FROM ZAGI_Sales_Dep.SOLDVIA AS sv, ZAGI_Sales_Dep.PRODUCT
AS p, ZAGI_Sales_Dep.SALESTRANSACTION AS st WHERE sv.ProductID = p.ProductID AND
sv.TID = st.TID;
INSERT INTO ZAGI_Dimensional.SALES_FACT (CalendarKey, StoreKey, ProductKey, CustomerKey,
TID, TimeOfDay, DollarsSold, UnitsSold ) SELECT CA.CalendarKey, S.StoreKey, P.ProductKey,
CU.CustomerKey, SFV.TID, SFV.TimeOfDay, SFV.DollarsSold, SFV.UnitsSold FROM
ZAGI_Sales_Dep.SALES_FACT_VIEW AS SFV, ZAGI_Dimensional.CALENDAR_D AS CA,
ZAGI_Dimensional.PRODUCT_D AS P, ZAGI_Dimensional.STORE_D as S,
ZAGI_Dimensional.CUSTOMER_D AS CU WHERE CA.FullDate = SFV.TDate AND S.StoreID =
SFV.StoreID AND P.ProductID = SFV.ProductID AND CU.CustomerID = SFV.CustomerID;
E8.1b, E8.1c Aggregated Fact Table
A dimensional model above contains an aggregated fact table, which
shows a summary of units sold and dollars sold for daily purchases of
each product in each store. It is populated as shown below.
INSERT INTO ZAGI_Dimensional.AGGREGATED_FACT (CalendarKey, StoreKey,
ProductKey, DollarsSold, UnitsSold)
SELECT SF.CalendarKey, SF.StoreKey, SF.ProductKey, SUM(DollarsSold),
SUM(UnitsSold)
FROM ZAGI_Dimensional.SALES_FACT SF
GROUP BY CalendarKey, StoreKey, ProductKey;
Source 1: ZAGI Sales Department data
Source 2: ZAGI Facilities Department data
Source 3: Customer Demographic data
external table
ZAGI Sales Dimensional DW: fact tables
populated with data, Calendar dimension
ZAGI Sales Dimensional DW: Store, Product and
Customer Dimensions Populated with data
E8.2 City Police Department
Consider the following scenario involving the City Police Department.
The City Police Department wants to create an analytical database to
analyze its ticket revenue.
The two available data sources, Source 1 and Source 2, are described
below.
• Source 1 The City Police Department maintains the Ticketed
Violations Database, shown in Figure below.
• Source 2 The Department of Motor Vehicles (DMV) maintains the
Vehicle Registration Table, shown in Figure below
Source 1: CPD Ticketed Violations
Source 1: CPD Ticketed Violations
Source 2: DMV Vehicle Registration Table
E8.2 Ticket Revenue Data Warehouse
The data warehouse has to enable an analysis of ticket revenues by:
• date, including: full date day of week, day of month, month, quarter, year
• officer, including: officer ID, officer name, officer rank
• payer of the ticket, including: payer DLN, payer name, payer gender, payer
birth year
• vehicle, including: vehicle LPN, vehicle make, vehicle model, vehicle year,
vehicle owner DLN, vehicle owner name, vehicle owner gender, vehicle
owner birth year
• ticket type, including: ticket category (driving or parking), ticket violation,
ticket fee
Ticket Revenue Dimensional DW model
(star schema)
INSERT INTO statements
INSERT INTO CPD_Ticket_Revenue.CALENDAR (FullDate, DayOfWeek, DayOfMonth, Month, Quarter, Year )
SELECT DISTINCT DTDate as FullDate, DAYOFWEEK(DTDate) AS DayOfWeek, dayofmonth(DTDate) AS
DayOfMonth, month(DTDate) AS Month, quarter(DTDate) AS Qtr, year(DTDate) AS Year FROM
CPD_Ticketed_Violations.DRIVINGTICKET UNION SELECT DISTINCT PTDate as FullDate,
DAYOFWEEK(PTDate) AS DayOfWeek, dayofmonth(PTDate) AS DayOfMonth, month(PTDate) AS Month,
quarter(PTDate) AS Quarter, year(PTDate) AS Year FROM CPD_Ticketed_Violations.PARKINGTICKET;
INSERT INTO CPD_Ticket_Revenue.OFFICER (OfficerID, OfficerName, OfficerRank) SELECT OfficerID,
OfficerName, OfficerRank FROM CPD_Ticketed_Violations.OFFICER;
INSERT INTO CPD_Ticket_Revenue.TICKETTYPE (TicketCategory, TicketViolation, TicketFee) SELECT * FROM
CPD_Ticketed_Violations.DTICKETTYPE UNION SELECT * FROM CPD_Ticketed_Violations.PTICKETTYPE;
INSERT INTO CPD_Ticket_Revenue.PAYER (PayerDLN, PayerName, PayerGender, PayerBirthYear)SELECT *
FROM CPD_Ticketed_Violations.DRIVER;
INSERT INTO CPD_Ticket_Revenue.VEHICLE (VehicleLPN, VehicleMake, VehicleModel, VehicleYear,
VehicleOwnerDLN, VehicleOwnerName, VehicleOwnerGender, VehicleOwnerBirthYear) SELECT v1.VehicleLPN,
v2.VehicleMake, v2.VehicleModel, v2.VehicleYear, v2.OwnerDLN, v2.OwnerName, v2.OwnerGender,
OwnerBirthYear FROM CPD_Ticketed_Violations.VEHICLE AS v1, CPD_Vehicle_Registration_Table.VRT AS v2
WHERE v1.VehicleLPN = v2.VehicleLPN;
INSERT INTO CPD_Ticket_Revenue.REVENUE_FACT (CalendarKey, OfficerKey, PayerKey,
VehicleKey, TicketTypeKey, TicketID, Amount)SELECT C.CalendarKey, O.OfficerKey, P.PayerKey,
V.VehicleKey, TT.TicketTypeKey, dt.DTID AS TID, dtt.DTFee AS Amount FROM
CPD_Ticketed_Violations.DRIVINGTICKET dt, CPD_Ticketed_Violations.DTICKETTYPE dtt,
CPD_Ticket_Revenue.CALENDAR as C, CPD_Ticket_Revenue.PAYER as P,
CPD_Ticket_Revenue.VEHICLE as V, CPD_Ticket_Revenue.OFFICER as O,
CPD_Ticket_Revenue.TICKETTYPE AS TT WHERE dt.DTTypeID = dtt.DTTypeID and dt.OfficerID =
O.OfficerID and dt.DLN = P.PayerDLN and dt.VehicleLPN = V.VehicleLPN and dt.DTTypeID =
TT.TicketCategory and C.FullDate = dt.DTDateGROUP BY TID UNION SELECT C.CalendarKey,
O.OfficerKey, P.PayerKey, V.VehicleKey, TT.TicketTypeKey, pt.PTID AS TID, ptt.DTFee AS Amount
FROM CPD_Ticketed_Violations.PARKINGTICKET pt, CPD_Vehicle_Registration_Table.VRT vr,
CPD_Ticketed_Violations.PTICKETTYPE ptt, CPD_Ticket_Revenue.CALENDAR as C,
CPD_Ticket_Revenue.PAYER as P, CPD_Ticket_Revenue.VEHICLE as V,
CPD_Ticket_Revenue.OFFICER as O, CPD_Ticket_Revenue.TICKETTYPE AS TT WHERE
pt.PTTypeID = ptt.PTTypeID and pt.OfficerID = O.OfficerID and vr.OwnerDLN = P.PayerDLN and
pt.VehicleLPN = V.VehicleLPN and pt.PTTypeID = TT.TicketCategory and C.FullDate =
pt.PTDateGROUP BY TID;
E8.2b,c Aggregated fact table
A dimensional model above contains an aggregated fact table, which
shows a summary of daily revenue amount for each officer. It is
populated as shown below.
INSERT INTO CPD_Ticket_Revenue.REV_OFFICER_BY_DAY (CalendarKey,
OfficerKey, Revenue)
SELECT CalendarKey, OfficerKey, SUM(Amount)
FROM CPD_Ticket_Revenue.REVENUE_FACT
GROUP BY CalendarKey, OfficerKey;
Sources 1: CPD Ticketed Violations data
Source 2: DMV Vehicle Registration table
Ticket Revenue DW: Fact Tables populated
with data, Calendar dimension
Ticket Revenue DW: Payer, Vehicle, Officer and
TicketType Dimensions Populated with Data
E8.3 Big Z Inc. Automotive Products
Consider the following scenario involving Big Z Inc., an automotive
products wholesaler analytical database Big Z Inc. wants to create the
(data warehouse) to analyze its order quantities. The two available data
sources, Source 1 and Source 2, are described below.
The three available data sources are:
• Source 1 The Big Z Inc. Human Resources Department Table, shown
below.
• Source 2 The Big Z Inc. Orders Database, shown in Figure bellow.
Source 1: HR Department table
Source 2: Big Z Orders database
E8.3 Dimensional Warehouse
The data warehouse has to enable an analysis of order quantities by:
• date, including: full date, day of week, day of month, month, quarter, year
• time
• product, including product ID, product name, product type, product supplier
name
• customer, including: customer ID, customer name, customer type, customer zip
• depot, including depot ID, depot size, depot zip
• order clerk, including: order clerk id, order clerk name, order clerk title, order
clerk education level, order clerk year of hire
Based on the sources and requirements listed above, create a dimensional model
that will be used for the dimensionally modeled data warehouse for Big Z Inc.
Big Z Order Quantities Dimensional DW model
(star schema)
Big Z Orders Quantities Normalized schema
E8.3 INSERT INTO Statements
INSERT INTO BigZ_Dimensional.CALENDAR (FullDate, DayOfWeek, DayOfMonth,
MONTH, Quarter, YEAR)SELECT DISTINCT OrderDate AS FullDate,
DAYOFWEEK(OrderDate) AS DayOfWeek, dayofmonth(OrderDate) AS DayOfMonth,
month(OrderDate) AS MONTH, quarter(OrderDate) AS Qtr, year(OrderDate) AS YEAR
FROM BigZ_Orders.ORDER_;
INSERT INTO BigZ_Dimensional.CUSTOMER (CustomerID, CustomerName,
CustomerType, CustomerZip) SELECT * FROM BigZ_Orders.CUSTOMER;
INSERT INTO BigZ_Dimensional.DEPOT (DepotID, DepotSize, DepotZip)SELECT * FROM
BigZ_Orders.DEPOT;
INSERT INTO BigZ_Dimensional.ORDERCLERK (OCID, OCName, OCTitle, OCEducation,
OCYofhire) SELECT oc.OCID, oc.OCName, hr.Title, hr.EducationLevel, hr.YearOfHire
FROM BigZ_Orders.ORDERCLERK AS oc, BigZ_HR_Table.HRDEPARTMENT AS hr
WHERE oc.OCID = hr.EmployeeID;
INSERT INTO BigZ_Dimensional.PRODUCT (ProductID, ProductName, ProductType,
SupplierName)SELECT p.ProductID, p.ProductName, p.ProductType,
s.SupplierNameFROM BigZ_Orders.PRODUCT AS p, BigZ_Orders.SUPPLIER AS s
WHERE p.SupplierID = s.SupplierID;
INSERT INTO BigZ_Dimensional.ORDER_QUANTITY_FACT (CalendarKey, CustomerKey, DepotKey,
OrderClerkKey, ProductKey, OrderID, TIME, Quantity) SELECT C.CalendarKey, CU.CustomerKey,
D.DepotKey, OC.OCKey, P.ProductKey, OV.OrderID, O.OrderTime, sum(OV.Quantity) FROM
BigZ_Dimensional.CALENDAR AS C, BigZ_Dimensional.CUSTOMER AS CU,
BigZ_Dimensional.Depot AS D, BigZ_Dimensional.ORDERCLERK AS OC,
BigZ_Dimensional.PRODUCT AS P, BigZ_Orders.ORDER_ AS O, BigZ_Orders.ORDERVIA AS OV
WHERE O.OrderDate = C.FullDate AND O.CustomerID = CU.CustomerID AND O.DepotID =
D.DepotID AND O.OCID = OC.OCID AND OV.ProductID = P.ProductID AND OV.OrderID =
O.OrderIDGROUP BY OV.OrderID, OV.ProductID;
INSERT INTO BigZ_Normalized.ORDERCLERK (OCID, OCName, Title, EducationLevel, YearOfHire)
SELECT HR.EmployeeID as OCID, HR.Name as OCName, HR.Title, HR.EducationLevel,
HR.YearOfHire FROM BigZ_HR_Table.HRDEPARTMENT HR, BigZ_Orders.ORDERCLERK OC
WHERE HR.EmployeeID = OC.OCID;
INSERT INTO BigZ_Normalized.CUSTOMER SELECT *FROM BigZ_Orders.CUSTOMER;
INSERT INTO BigZ_Normalized.DEPOT SELECT *FROM BigZ_Orders.DEPOT;
INSERT INTO BigZ_Normalized.PRODUCT SELECT p.ProductID, p.ProductName, p.ProductType,
s.SupplierName FROM BigZ_Orders.PRODUCT AS p, BigZ_Orders.SUPPLIER AS s WHERE
p.SupplierID = s.SupplierID;
INSERT INTO BigZ_Normalized.ORDER_SELECT * FROM BigZ_Orders.ORDER_;
INSERT INTO BigZ_Normalized.ORDERVIA SELECT * FROM BigZ_Orders.ORDERVIA;
Source 1: HR Department table
Source 2: Big Z Orders Database
E8.3 Dimensional DW: Fact Table populated
with data, Calendar dimension
E8.3 Dimensional DW: Customer, Depot, Order
Clerk and Product dimensions with data
References:
Jukic N., Vrbsky S., Nestorov S. “Database Systems. Introduction to
Databases and Data Warehouses”. Pearson Education Inc., 2014.
1 von 41

Recomendados

advanced sql(database) von
advanced sql(database)advanced sql(database)
advanced sql(database)welcometofacebook
2.3K views27 Folien
Oracle SQL Basics von
Oracle SQL BasicsOracle SQL Basics
Oracle SQL BasicsDhananjay Goel
6.9K views40 Folien
Sas practice programs von
Sas practice programsSas practice programs
Sas practice programsgowthami marreddy
359 views48 Folien
Group By, Having Clause and Order By clause von
Group By, Having Clause and Order By clause Group By, Having Clause and Order By clause
Group By, Having Clause and Order By clause Deepam Aggarwal
387 views5 Folien
DATABASE CONSTRAINTS von
DATABASE CONSTRAINTSDATABASE CONSTRAINTS
DATABASE CONSTRAINTSsunanditaAnand
4.7K views9 Folien
Testing SQL von
Testing SQLTesting SQL
Testing SQLForrester High School
161 views12 Folien

Más contenido relacionado

Was ist angesagt?

Air Ticket Price Prediction.pdf von
Air Ticket Price Prediction.pdfAir Ticket Price Prediction.pdf
Air Ticket Price Prediction.pdfAdityaAryan45
480 views15 Folien
Chapter 2 grouping,scalar and aggergate functions,joins inner join,outer join von
Chapter 2  grouping,scalar and aggergate functions,joins   inner join,outer joinChapter 2  grouping,scalar and aggergate functions,joins   inner join,outer join
Chapter 2 grouping,scalar and aggergate functions,joins inner join,outer joinbaabtra.com - No. 1 supplier of quality freshers
1.7K views33 Folien
Sql subquery von
Sql  subquerySql  subquery
Sql subqueryRaveena Thakur
7.1K views15 Folien
Binary search tree deletion von
Binary search tree deletionBinary search tree deletion
Binary search tree deletionKousalya M
1K views13 Folien
Radix Sort von
Radix SortRadix Sort
Radix SortFaiza Saleem
503 views8 Folien
Sql notes, sql server,sql queries,introduction of SQL, Beginner in SQL von
Sql notes, sql server,sql queries,introduction of SQL, Beginner in SQLSql notes, sql server,sql queries,introduction of SQL, Beginner in SQL
Sql notes, sql server,sql queries,introduction of SQL, Beginner in SQLPrashant Kumar
1.2K views80 Folien

Was ist angesagt?(20)

Air Ticket Price Prediction.pdf von AdityaAryan45
Air Ticket Price Prediction.pdfAir Ticket Price Prediction.pdf
Air Ticket Price Prediction.pdf
AdityaAryan45480 views
Binary search tree deletion von Kousalya M
Binary search tree deletionBinary search tree deletion
Binary search tree deletion
Kousalya M1K views
Sql notes, sql server,sql queries,introduction of SQL, Beginner in SQL von Prashant Kumar
Sql notes, sql server,sql queries,introduction of SQL, Beginner in SQLSql notes, sql server,sql queries,introduction of SQL, Beginner in SQL
Sql notes, sql server,sql queries,introduction of SQL, Beginner in SQL
Prashant Kumar1.2K views
Introduction to structured query language (sql) von Sabana Maharjan
Introduction to structured query language (sql)Introduction to structured query language (sql)
Introduction to structured query language (sql)
Sabana Maharjan693 views
Selection sort von amna izzat
Selection sortSelection sort
Selection sort
amna izzat7.1K views
The Titanic - machine learning from disaster von Mostafa Nizam
The Titanic - machine learning from disasterThe Titanic - machine learning from disaster
The Titanic - machine learning from disaster
Mostafa Nizam655 views
Payroll costing details Oracle Fusion Cloud HCM von Feras Ahmad
Payroll costing details Oracle Fusion Cloud HCMPayroll costing details Oracle Fusion Cloud HCM
Payroll costing details Oracle Fusion Cloud HCM
Feras Ahmad1.7K views
introdution to SQL and SQL functions von farwa waqar
introdution to SQL and SQL functionsintrodution to SQL and SQL functions
introdution to SQL and SQL functions
farwa waqar3.8K views
Data warehouse implementation design for a Retail business von Arsalan Qadri
Data warehouse implementation design for a Retail businessData warehouse implementation design for a Retail business
Data warehouse implementation design for a Retail business
Arsalan Qadri5.8K views
SQL Functions von ammarbrohi
SQL FunctionsSQL Functions
SQL Functions
ammarbrohi5.3K views

Destacado

Database Project von
Database ProjectDatabase Project
Database ProjectValerii Klymchuk
22.6K views58 Folien
02 Related Concepts von
02 Related Concepts02 Related Concepts
02 Related ConceptsValerii Klymchuk
1.1K views12 Folien
04 Classification in Data Mining von
04 Classification in Data Mining04 Classification in Data Mining
04 Classification in Data MiningValerii Klymchuk
11.6K views29 Folien
03 Data Mining Techniques von
03 Data Mining Techniques03 Data Mining Techniques
03 Data Mining TechniquesValerii Klymchuk
1.6K views13 Folien
01 Introduction to Data Mining von
01 Introduction to Data Mining01 Introduction to Data Mining
01 Introduction to Data MiningValerii Klymchuk
2.8K views14 Folien
05 Clustering in Data Mining von
05 Clustering in Data Mining05 Clustering in Data Mining
05 Clustering in Data MiningValerii Klymchuk
7.8K views32 Folien

Destacado(9)

Similar a Data Warehouse Project

Smartplex1 von
Smartplex1Smartplex1
Smartplex1Venkata Subramanian
237 views11 Folien
Data visualization for e commerce of jcpenney von
Data visualization for e commerce of jcpenneyData visualization for e commerce of jcpenney
Data visualization for e commerce of jcpenneyTrupti Shingala, WAS, CPACC, CPWA, JAWS, CSM
1.3K views27 Folien
Exploiting data quality tools to meet the expectation of strategic business u... von
Exploiting data quality tools to meet the expectation of strategic business u...Exploiting data quality tools to meet the expectation of strategic business u...
Exploiting data quality tools to meet the expectation of strategic business u...Zubair Abbasi
502 views29 Folien
T5 von
T5T5
T5NidhiGupta8431
199 views5 Folien
MSA_8110_Final_Project von
MSA_8110_Final_ProjectMSA_8110_Final_Project
MSA_8110_Final_ProjectChristina Pemberton
432 views12 Folien
945 mpp1 chicago_taxi data research_v1_cyy_33w1xtp von
945 mpp1 chicago_taxi data research_v1_cyy_33w1xtp945 mpp1 chicago_taxi data research_v1_cyy_33w1xtp
945 mpp1 chicago_taxi data research_v1_cyy_33w1xtpRajprakash Dwivedi
39 views22 Folien

Similar a Data Warehouse Project(20)

Exploiting data quality tools to meet the expectation of strategic business u... von Zubair Abbasi
Exploiting data quality tools to meet the expectation of strategic business u...Exploiting data quality tools to meet the expectation of strategic business u...
Exploiting data quality tools to meet the expectation of strategic business u...
Zubair Abbasi502 views
945 mpp1 chicago_taxi data research_v1_cyy_33w1xtp von Rajprakash Dwivedi
945 mpp1 chicago_taxi data research_v1_cyy_33w1xtp945 mpp1 chicago_taxi data research_v1_cyy_33w1xtp
945 mpp1 chicago_taxi data research_v1_cyy_33w1xtp
Tn shaw 107 data warehousing problem set von TejNarayanShaw2
Tn shaw 107 data warehousing problem setTn shaw 107 data warehousing problem set
Tn shaw 107 data warehousing problem set
TejNarayanShaw285 views
207828627 sap-bootcamp-quiz-sd von homeworkping8
207828627 sap-bootcamp-quiz-sd207828627 sap-bootcamp-quiz-sd
207828627 sap-bootcamp-quiz-sd
homeworkping862 views
End to-end machine learning project for beginners von Sharath Kumar
End to-end machine learning project for beginnersEnd to-end machine learning project for beginners
End to-end machine learning project for beginners
Sharath Kumar67 views
DW DIMENSN MODELNG von Divya Tadi
DW DIMENSN MODELNGDW DIMENSN MODELNG
DW DIMENSN MODELNG
Divya Tadi373 views
AutoBooom write up-sample or Details von Rajendra suman
AutoBooom write up-sample or DetailsAutoBooom write up-sample or Details
AutoBooom write up-sample or Details
Rajendra suman611 views
PYTHON programming.pptx von SoojBonthu
PYTHON programming.pptxPYTHON programming.pptx
PYTHON programming.pptx
SoojBonthu31 views
Document process v7 von Bala Kris
Document process v7Document process v7
Document process v7
Bala Kris54 views

Más de Valerii Klymchuk

Sample presentation slides template von
Sample presentation slides templateSample presentation slides template
Sample presentation slides templateValerii Klymchuk
237 views38 Folien
Toronto Capstone von
Toronto CapstoneToronto Capstone
Toronto CapstoneValerii Klymchuk
288 views47 Folien
05 Scalar Visualization von
05 Scalar Visualization05 Scalar Visualization
05 Scalar VisualizationValerii Klymchuk
2.5K views11 Folien
06 Vector Visualization von
06 Vector Visualization06 Vector Visualization
06 Vector VisualizationValerii Klymchuk
3.2K views23 Folien
07 Tensor Visualization von
07 Tensor Visualization07 Tensor Visualization
07 Tensor VisualizationValerii Klymchuk
1.1K views13 Folien
Crime Analysis based on Historical and Transportation Data von
Crime Analysis based on Historical and Transportation DataCrime Analysis based on Historical and Transportation Data
Crime Analysis based on Historical and Transportation DataValerii Klymchuk
714 views10 Folien

Más de Valerii Klymchuk(6)

Último

CRIJ4385_Death Penalty_F23.pptx von
CRIJ4385_Death Penalty_F23.pptxCRIJ4385_Death Penalty_F23.pptx
CRIJ4385_Death Penalty_F23.pptxyvettemm100
6 views24 Folien
[DSC Europe 23] Milos Grubjesic Empowering Business with Pepsico s Advanced M... von
[DSC Europe 23] Milos Grubjesic Empowering Business with Pepsico s Advanced M...[DSC Europe 23] Milos Grubjesic Empowering Business with Pepsico s Advanced M...
[DSC Europe 23] Milos Grubjesic Empowering Business with Pepsico s Advanced M...DataScienceConferenc1
5 views11 Folien
3196 The Case of The East River von
3196 The Case of The East River3196 The Case of The East River
3196 The Case of The East RiverErickANDRADE90
11 views4 Folien
Vikas 500 BIG DATA TECHNOLOGIES LAB.pdf von
Vikas 500 BIG DATA TECHNOLOGIES LAB.pdfVikas 500 BIG DATA TECHNOLOGIES LAB.pdf
Vikas 500 BIG DATA TECHNOLOGIES LAB.pdfvikas12611618
8 views30 Folien
Advanced_Recommendation_Systems_Presentation.pptx von
Advanced_Recommendation_Systems_Presentation.pptxAdvanced_Recommendation_Systems_Presentation.pptx
Advanced_Recommendation_Systems_Presentation.pptxneeharikasingh29
5 views9 Folien
UNEP FI CRS Climate Risk Results.pptx von
UNEP FI CRS Climate Risk Results.pptxUNEP FI CRS Climate Risk Results.pptx
UNEP FI CRS Climate Risk Results.pptxpekka28
11 views51 Folien

Último(20)

CRIJ4385_Death Penalty_F23.pptx von yvettemm100
CRIJ4385_Death Penalty_F23.pptxCRIJ4385_Death Penalty_F23.pptx
CRIJ4385_Death Penalty_F23.pptx
yvettemm1006 views
[DSC Europe 23] Milos Grubjesic Empowering Business with Pepsico s Advanced M... von DataScienceConferenc1
[DSC Europe 23] Milos Grubjesic Empowering Business with Pepsico s Advanced M...[DSC Europe 23] Milos Grubjesic Empowering Business with Pepsico s Advanced M...
[DSC Europe 23] Milos Grubjesic Empowering Business with Pepsico s Advanced M...
Vikas 500 BIG DATA TECHNOLOGIES LAB.pdf von vikas12611618
Vikas 500 BIG DATA TECHNOLOGIES LAB.pdfVikas 500 BIG DATA TECHNOLOGIES LAB.pdf
Vikas 500 BIG DATA TECHNOLOGIES LAB.pdf
vikas126116188 views
Advanced_Recommendation_Systems_Presentation.pptx von neeharikasingh29
Advanced_Recommendation_Systems_Presentation.pptxAdvanced_Recommendation_Systems_Presentation.pptx
Advanced_Recommendation_Systems_Presentation.pptx
UNEP FI CRS Climate Risk Results.pptx von pekka28
UNEP FI CRS Climate Risk Results.pptxUNEP FI CRS Climate Risk Results.pptx
UNEP FI CRS Climate Risk Results.pptx
pekka2811 views
Organic Shopping in Google Analytics 4.pdf von GA4 Tutorials
Organic Shopping in Google Analytics 4.pdfOrganic Shopping in Google Analytics 4.pdf
Organic Shopping in Google Analytics 4.pdf
GA4 Tutorials11 views
[DSC Europe 23] Spela Poklukar & Tea Brasanac - Retrieval Augmented Generation von DataScienceConferenc1
[DSC Europe 23] Spela Poklukar & Tea Brasanac - Retrieval Augmented Generation[DSC Europe 23] Spela Poklukar & Tea Brasanac - Retrieval Augmented Generation
[DSC Europe 23] Spela Poklukar & Tea Brasanac - Retrieval Augmented Generation
Short Story Assignment by Kelly Nguyen von kellynguyen01
Short Story Assignment by Kelly NguyenShort Story Assignment by Kelly Nguyen
Short Story Assignment by Kelly Nguyen
kellynguyen0119 views
Ukraine Infographic_22NOV2023_v2.pdf von AnastosiyaGurin
Ukraine Infographic_22NOV2023_v2.pdfUkraine Infographic_22NOV2023_v2.pdf
Ukraine Infographic_22NOV2023_v2.pdf
AnastosiyaGurin1.3K views
[DSC Europe 23] Zsolt Feleki - Machine Translation should we trust it.pptx von DataScienceConferenc1
[DSC Europe 23] Zsolt Feleki - Machine Translation should we trust it.pptx[DSC Europe 23] Zsolt Feleki - Machine Translation should we trust it.pptx
[DSC Europe 23] Zsolt Feleki - Machine Translation should we trust it.pptx
Survey on Factuality in LLM's.pptx von NeethaSherra1
Survey on Factuality in LLM's.pptxSurvey on Factuality in LLM's.pptx
Survey on Factuality in LLM's.pptx
NeethaSherra15 views

Data Warehouse Project

  • 1. Database Systems Introduction to Databases and Data Warehouses (Solutions to end-of-chapter exercises E8.1, E8.2, E8.3)
  • 2. E8.1 ZAGI Retail Company Consider the following, slightly modified, ZAGI Retail Company scenario. The ZAGI Retail Company wants to create analytical database to analyze sales. The three available data sources are: • Source 1 The ZAGI Retail Company Sales Department Database, as shown below) • Source 2 The ZAGI Retail Company Facilities Department Database shown below • Source 3 A Customer Demographic Data external table shown below.
  • 3. Source 1: ZAGI Sales Department
  • 4. Source 2: ZAGI Facilities Department
  • 5. Source 3: Customer Demographic external table
  • 6. E8.1 ZAGI Retail Company data warehouse The data warehouse has to enable an analysis of sales dollar amounts and quantities by • date, including: full date, day of week, day of month, month quarter, year • time • product, including: product name and price, product category, product vendor • customer, including: customer name, zip, gender, marital status, education level, credit score • store, including: individual store, store size and store zip, store checkout system, store layout, store region.
  • 7. ZAGI Sales Dimensional DW model (star schema)
  • 8. INSERT INTO Statements INSERT INTO ZAGI_Dimensional.CALENDAR_D (FullDate, DayOfWeek, DayOfMonth, Month, Qtr, Year ) SELECT DISTINCT TDate as FullDate, DAYOFWEEK(tdate) AS DayOfWeek, dayofmonth(tdate) AS DayOfMonth, month(tdate) AS Month, quarter(tdate) AS Qtr, year(tdate) AS Year FROM SALESTRANSACTION; INSERT INTO ZAGI_Dimensional.PRODUCT_D (ProductID, ProductName, ProductPrice, ProductVendorName, ProductCategoryName ) SELECT p.ProductID as ProductID, p.ProductName, p.ProductPrice, v.VendorName AS ProductVendorName, c.CategoryName AS ProductCategoryName FROM PRODUCT p, VENDOR v, CATEGORY c WHERE p.VendorID = v.VendorID AND p.CategoryID = c.CategoryID GROUP BY p.ProductID; INSERT INTO ZAGI_Dimensional.STORE_D (StoreID, StoreZip, StoreRegionName, StoreSize, StoreCSystem, StoreLayout ) SELECT s.StoreID as StoreId, s.StoreZip AS StoreZip, r.RegionName AS StoreRegionName, s1.StoreSize AS StoreSize, cs.CSystem AS StoreCSystem, l.Layout AS StoreLayout FROM ZAGI_Sales_Dep.STORE s, ZAGI_Sales_Dep.REGION r, ZAGI_Facilities_Dep.STORE1 s1, ZAGI_Facilities_Dep.CHECKOUTSYSTEM cs, ZAGI_Facilities_Dep.LAYOUT l WHERE r.RegionID = s.RegionID AND s.StoreID=s1.StoreID AND s1.CSID = cs.CSID AND s1.LTID = l.LayoutID GROUP BY s.StoreID;
  • 9. INSERT INTO ZAGI_Dimensional.CUSTOMER_D(CustomerID, CustomerName, CustomerZip, CustomerGender, CustomerMaritalStatus, CustomerEducationLevel, CustomerCreditScore )SELECT t1.customerid as CustomerId, t1.customername AS CustomerName, t1.customerzip AS CustomerZip, t2.gender AS CustomerGender, t2.maritalstatus AS CustomerMaritalStatus, t2.educationlevel AS CustomerEducationLevel, t2.creditscore AS CustomerCreditScore FROM ZAGI_Sales_Dep.CUSTOMER AS t1, ZAGI_Customer_Table.CUSTOMER_TABLE AS t2 WHERE t1.CustomerID = t2.CustomerID; CREATE VIEW `SALES_FACT_VIEW` AS SELECT st.TDate, st.StoreID, sv.ProductID, st.CustomerID, sv.TID AS TID, st.TTime AS TimeOfDay, p.ProductPrice*sv.NoOfItems AS DollarsSold, sv.NoOfItems AS UnitsSold FROM ZAGI_Sales_Dep.SOLDVIA AS sv, ZAGI_Sales_Dep.PRODUCT AS p, ZAGI_Sales_Dep.SALESTRANSACTION AS st WHERE sv.ProductID = p.ProductID AND sv.TID = st.TID; INSERT INTO ZAGI_Dimensional.SALES_FACT (CalendarKey, StoreKey, ProductKey, CustomerKey, TID, TimeOfDay, DollarsSold, UnitsSold ) SELECT CA.CalendarKey, S.StoreKey, P.ProductKey, CU.CustomerKey, SFV.TID, SFV.TimeOfDay, SFV.DollarsSold, SFV.UnitsSold FROM ZAGI_Sales_Dep.SALES_FACT_VIEW AS SFV, ZAGI_Dimensional.CALENDAR_D AS CA, ZAGI_Dimensional.PRODUCT_D AS P, ZAGI_Dimensional.STORE_D as S, ZAGI_Dimensional.CUSTOMER_D AS CU WHERE CA.FullDate = SFV.TDate AND S.StoreID = SFV.StoreID AND P.ProductID = SFV.ProductID AND CU.CustomerID = SFV.CustomerID;
  • 10. E8.1b, E8.1c Aggregated Fact Table A dimensional model above contains an aggregated fact table, which shows a summary of units sold and dollars sold for daily purchases of each product in each store. It is populated as shown below. INSERT INTO ZAGI_Dimensional.AGGREGATED_FACT (CalendarKey, StoreKey, ProductKey, DollarsSold, UnitsSold) SELECT SF.CalendarKey, SF.StoreKey, SF.ProductKey, SUM(DollarsSold), SUM(UnitsSold) FROM ZAGI_Dimensional.SALES_FACT SF GROUP BY CalendarKey, StoreKey, ProductKey;
  • 11. Source 1: ZAGI Sales Department data
  • 12. Source 2: ZAGI Facilities Department data
  • 13. Source 3: Customer Demographic data external table
  • 14. ZAGI Sales Dimensional DW: fact tables populated with data, Calendar dimension
  • 15. ZAGI Sales Dimensional DW: Store, Product and Customer Dimensions Populated with data
  • 16. E8.2 City Police Department Consider the following scenario involving the City Police Department. The City Police Department wants to create an analytical database to analyze its ticket revenue. The two available data sources, Source 1 and Source 2, are described below. • Source 1 The City Police Department maintains the Ticketed Violations Database, shown in Figure below. • Source 2 The Department of Motor Vehicles (DMV) maintains the Vehicle Registration Table, shown in Figure below
  • 17. Source 1: CPD Ticketed Violations
  • 18. Source 1: CPD Ticketed Violations
  • 19. Source 2: DMV Vehicle Registration Table
  • 20. E8.2 Ticket Revenue Data Warehouse The data warehouse has to enable an analysis of ticket revenues by: • date, including: full date day of week, day of month, month, quarter, year • officer, including: officer ID, officer name, officer rank • payer of the ticket, including: payer DLN, payer name, payer gender, payer birth year • vehicle, including: vehicle LPN, vehicle make, vehicle model, vehicle year, vehicle owner DLN, vehicle owner name, vehicle owner gender, vehicle owner birth year • ticket type, including: ticket category (driving or parking), ticket violation, ticket fee
  • 21. Ticket Revenue Dimensional DW model (star schema)
  • 22. INSERT INTO statements INSERT INTO CPD_Ticket_Revenue.CALENDAR (FullDate, DayOfWeek, DayOfMonth, Month, Quarter, Year ) SELECT DISTINCT DTDate as FullDate, DAYOFWEEK(DTDate) AS DayOfWeek, dayofmonth(DTDate) AS DayOfMonth, month(DTDate) AS Month, quarter(DTDate) AS Qtr, year(DTDate) AS Year FROM CPD_Ticketed_Violations.DRIVINGTICKET UNION SELECT DISTINCT PTDate as FullDate, DAYOFWEEK(PTDate) AS DayOfWeek, dayofmonth(PTDate) AS DayOfMonth, month(PTDate) AS Month, quarter(PTDate) AS Quarter, year(PTDate) AS Year FROM CPD_Ticketed_Violations.PARKINGTICKET; INSERT INTO CPD_Ticket_Revenue.OFFICER (OfficerID, OfficerName, OfficerRank) SELECT OfficerID, OfficerName, OfficerRank FROM CPD_Ticketed_Violations.OFFICER; INSERT INTO CPD_Ticket_Revenue.TICKETTYPE (TicketCategory, TicketViolation, TicketFee) SELECT * FROM CPD_Ticketed_Violations.DTICKETTYPE UNION SELECT * FROM CPD_Ticketed_Violations.PTICKETTYPE; INSERT INTO CPD_Ticket_Revenue.PAYER (PayerDLN, PayerName, PayerGender, PayerBirthYear)SELECT * FROM CPD_Ticketed_Violations.DRIVER; INSERT INTO CPD_Ticket_Revenue.VEHICLE (VehicleLPN, VehicleMake, VehicleModel, VehicleYear, VehicleOwnerDLN, VehicleOwnerName, VehicleOwnerGender, VehicleOwnerBirthYear) SELECT v1.VehicleLPN, v2.VehicleMake, v2.VehicleModel, v2.VehicleYear, v2.OwnerDLN, v2.OwnerName, v2.OwnerGender, OwnerBirthYear FROM CPD_Ticketed_Violations.VEHICLE AS v1, CPD_Vehicle_Registration_Table.VRT AS v2 WHERE v1.VehicleLPN = v2.VehicleLPN;
  • 23. INSERT INTO CPD_Ticket_Revenue.REVENUE_FACT (CalendarKey, OfficerKey, PayerKey, VehicleKey, TicketTypeKey, TicketID, Amount)SELECT C.CalendarKey, O.OfficerKey, P.PayerKey, V.VehicleKey, TT.TicketTypeKey, dt.DTID AS TID, dtt.DTFee AS Amount FROM CPD_Ticketed_Violations.DRIVINGTICKET dt, CPD_Ticketed_Violations.DTICKETTYPE dtt, CPD_Ticket_Revenue.CALENDAR as C, CPD_Ticket_Revenue.PAYER as P, CPD_Ticket_Revenue.VEHICLE as V, CPD_Ticket_Revenue.OFFICER as O, CPD_Ticket_Revenue.TICKETTYPE AS TT WHERE dt.DTTypeID = dtt.DTTypeID and dt.OfficerID = O.OfficerID and dt.DLN = P.PayerDLN and dt.VehicleLPN = V.VehicleLPN and dt.DTTypeID = TT.TicketCategory and C.FullDate = dt.DTDateGROUP BY TID UNION SELECT C.CalendarKey, O.OfficerKey, P.PayerKey, V.VehicleKey, TT.TicketTypeKey, pt.PTID AS TID, ptt.DTFee AS Amount FROM CPD_Ticketed_Violations.PARKINGTICKET pt, CPD_Vehicle_Registration_Table.VRT vr, CPD_Ticketed_Violations.PTICKETTYPE ptt, CPD_Ticket_Revenue.CALENDAR as C, CPD_Ticket_Revenue.PAYER as P, CPD_Ticket_Revenue.VEHICLE as V, CPD_Ticket_Revenue.OFFICER as O, CPD_Ticket_Revenue.TICKETTYPE AS TT WHERE pt.PTTypeID = ptt.PTTypeID and pt.OfficerID = O.OfficerID and vr.OwnerDLN = P.PayerDLN and pt.VehicleLPN = V.VehicleLPN and pt.PTTypeID = TT.TicketCategory and C.FullDate = pt.PTDateGROUP BY TID;
  • 24. E8.2b,c Aggregated fact table A dimensional model above contains an aggregated fact table, which shows a summary of daily revenue amount for each officer. It is populated as shown below. INSERT INTO CPD_Ticket_Revenue.REV_OFFICER_BY_DAY (CalendarKey, OfficerKey, Revenue) SELECT CalendarKey, OfficerKey, SUM(Amount) FROM CPD_Ticket_Revenue.REVENUE_FACT GROUP BY CalendarKey, OfficerKey;
  • 25. Sources 1: CPD Ticketed Violations data
  • 26. Source 2: DMV Vehicle Registration table
  • 27. Ticket Revenue DW: Fact Tables populated with data, Calendar dimension
  • 28. Ticket Revenue DW: Payer, Vehicle, Officer and TicketType Dimensions Populated with Data
  • 29. E8.3 Big Z Inc. Automotive Products Consider the following scenario involving Big Z Inc., an automotive products wholesaler analytical database Big Z Inc. wants to create the (data warehouse) to analyze its order quantities. The two available data sources, Source 1 and Source 2, are described below. The three available data sources are: • Source 1 The Big Z Inc. Human Resources Department Table, shown below. • Source 2 The Big Z Inc. Orders Database, shown in Figure bellow.
  • 30. Source 1: HR Department table
  • 31. Source 2: Big Z Orders database
  • 32. E8.3 Dimensional Warehouse The data warehouse has to enable an analysis of order quantities by: • date, including: full date, day of week, day of month, month, quarter, year • time • product, including product ID, product name, product type, product supplier name • customer, including: customer ID, customer name, customer type, customer zip • depot, including depot ID, depot size, depot zip • order clerk, including: order clerk id, order clerk name, order clerk title, order clerk education level, order clerk year of hire Based on the sources and requirements listed above, create a dimensional model that will be used for the dimensionally modeled data warehouse for Big Z Inc.
  • 33. Big Z Order Quantities Dimensional DW model (star schema)
  • 34. Big Z Orders Quantities Normalized schema
  • 35. E8.3 INSERT INTO Statements INSERT INTO BigZ_Dimensional.CALENDAR (FullDate, DayOfWeek, DayOfMonth, MONTH, Quarter, YEAR)SELECT DISTINCT OrderDate AS FullDate, DAYOFWEEK(OrderDate) AS DayOfWeek, dayofmonth(OrderDate) AS DayOfMonth, month(OrderDate) AS MONTH, quarter(OrderDate) AS Qtr, year(OrderDate) AS YEAR FROM BigZ_Orders.ORDER_; INSERT INTO BigZ_Dimensional.CUSTOMER (CustomerID, CustomerName, CustomerType, CustomerZip) SELECT * FROM BigZ_Orders.CUSTOMER; INSERT INTO BigZ_Dimensional.DEPOT (DepotID, DepotSize, DepotZip)SELECT * FROM BigZ_Orders.DEPOT; INSERT INTO BigZ_Dimensional.ORDERCLERK (OCID, OCName, OCTitle, OCEducation, OCYofhire) SELECT oc.OCID, oc.OCName, hr.Title, hr.EducationLevel, hr.YearOfHire FROM BigZ_Orders.ORDERCLERK AS oc, BigZ_HR_Table.HRDEPARTMENT AS hr WHERE oc.OCID = hr.EmployeeID; INSERT INTO BigZ_Dimensional.PRODUCT (ProductID, ProductName, ProductType, SupplierName)SELECT p.ProductID, p.ProductName, p.ProductType, s.SupplierNameFROM BigZ_Orders.PRODUCT AS p, BigZ_Orders.SUPPLIER AS s WHERE p.SupplierID = s.SupplierID;
  • 36. INSERT INTO BigZ_Dimensional.ORDER_QUANTITY_FACT (CalendarKey, CustomerKey, DepotKey, OrderClerkKey, ProductKey, OrderID, TIME, Quantity) SELECT C.CalendarKey, CU.CustomerKey, D.DepotKey, OC.OCKey, P.ProductKey, OV.OrderID, O.OrderTime, sum(OV.Quantity) FROM BigZ_Dimensional.CALENDAR AS C, BigZ_Dimensional.CUSTOMER AS CU, BigZ_Dimensional.Depot AS D, BigZ_Dimensional.ORDERCLERK AS OC, BigZ_Dimensional.PRODUCT AS P, BigZ_Orders.ORDER_ AS O, BigZ_Orders.ORDERVIA AS OV WHERE O.OrderDate = C.FullDate AND O.CustomerID = CU.CustomerID AND O.DepotID = D.DepotID AND O.OCID = OC.OCID AND OV.ProductID = P.ProductID AND OV.OrderID = O.OrderIDGROUP BY OV.OrderID, OV.ProductID; INSERT INTO BigZ_Normalized.ORDERCLERK (OCID, OCName, Title, EducationLevel, YearOfHire) SELECT HR.EmployeeID as OCID, HR.Name as OCName, HR.Title, HR.EducationLevel, HR.YearOfHire FROM BigZ_HR_Table.HRDEPARTMENT HR, BigZ_Orders.ORDERCLERK OC WHERE HR.EmployeeID = OC.OCID; INSERT INTO BigZ_Normalized.CUSTOMER SELECT *FROM BigZ_Orders.CUSTOMER; INSERT INTO BigZ_Normalized.DEPOT SELECT *FROM BigZ_Orders.DEPOT; INSERT INTO BigZ_Normalized.PRODUCT SELECT p.ProductID, p.ProductName, p.ProductType, s.SupplierName FROM BigZ_Orders.PRODUCT AS p, BigZ_Orders.SUPPLIER AS s WHERE p.SupplierID = s.SupplierID; INSERT INTO BigZ_Normalized.ORDER_SELECT * FROM BigZ_Orders.ORDER_; INSERT INTO BigZ_Normalized.ORDERVIA SELECT * FROM BigZ_Orders.ORDERVIA;
  • 37. Source 1: HR Department table
  • 38. Source 2: Big Z Orders Database
  • 39. E8.3 Dimensional DW: Fact Table populated with data, Calendar dimension
  • 40. E8.3 Dimensional DW: Customer, Depot, Order Clerk and Product dimensions with data
  • 41. References: Jukic N., Vrbsky S., Nestorov S. “Database Systems. Introduction to Databases and Data Warehouses”. Pearson Education Inc., 2014.