Short note on Fact Constellations Schema.

 Fact Constellations Schema

  • This kind of schema can be viewed as a collection of stars, and hence is called a galaxy schema or a fact constellation.
  •  A fact constellation schema allows dimension tables to be shared between fact tables. 
  • For example, the following schema specifies two fact tables, sales, and shipping. 
- The sales table definition is identical to that of the star schema. 
- The shipping table has five dimensions or keys: item key, time key, shipper key, from location, and to location, and two measures: dollars cost and units shipped.








Defining a Fact Constellation in DMQL
define cube sales [time, item, branch, location]:

dollars_sold = sum(sales_in_dollars), avg_sales = avg(sales_in_dollars), units_sold = count(*)

define dimension time as (time_key, day, day_of_week, month, quarter, year)
define dimension item as (item_key, item_name, brand, type, supplier_type)
define dimension branch as (branch_key, branch_name, branch_type)
define dimension location as (location_key, street, city, province_or_state, country)
define cube shipping [time, item, shipper, from_location, to_location]:
dollar_cost = sum(cost_in_dollars), unit_shipped = count(*)
define dimension time as time in cube sales
define dimension item as item in cube sales
define dimension shipper as (shipper_key, shipper_name, location as location in cube sales, shipper_type)
define dimension from_location as location in cube sales
define dimension to_location as location in cube sales

OR,







Comments

Popular posts from this blog

What is RMI? Discuss stub and skeleton. Explain its role in creating distributed applications.

Discuss classification or taxonomy of virtualization at different levels.

Explain CORBA architecture briefly.