You are on page 1of 3

Name: Siddhi Sunil Khade

Division: TE3
Batch: B
Roll. No: 22

Experiment 3: Implementation of OLAP operations: Slice, Dice, Rollup,


Drilldown and Pivot based on experiment 1 case study.
Problem Statement:
Design a data warehouse for a regional weather bureau. The weather bureau has about 100 probs, which
are scattered throughout various land and ocean locations in the region to collect basic weather data,
including air pressure, temperature and precipitation at each hour. All data are sent to the central station,
which has collected such data for more than 10 years. Design Star schema and Snowflake schema such that
it should facilitate efficient querying and online analytical processing and derive general weather patterns in
multidimensional space.

1. Roll-Up
SELECT day, count(season) FROM time_dm GROUP BY ROLLUP (day);
2. Drill Down Operation
Select * From Region_dm Inner join Temperature_dm on
Region_dm.region_id=Temperature_dm.region_id;

3. Slice Operation
Select * From Region_dm Inner join Temperature_dm on
Region_dm.region_id=Temperature_dm.region_id where district ='Mumbai';
4. Dice Operation
Select region_name, probe_location, temperature_magnitude, temp_unit, precipitation_magnitude
From Region_dm Inner join Temperature_dm on Region_dm.region_id=Temperature_dm.region_id join
Precipitation_dm on Region_dm.region_id=Precipitation_dm.region_id where probe_location ='Panvel'
and district='Mumbai';

5. Pivot Operation
Select * From Temperature_dm Pivot (Count(temperature_id for region _id In ('1','2','3','4','5') );

You might also like