Saturday, April 10, 2010

Star Shema and OLAP

STAR SCHEMA
also known as star join schema.
Don't get so worried about Star schema, it is important to know about it, because it builds up the concept of Multidimensional database system.
"It is a method or a way to implement a multidimensional data base system from relational database".............
So what does this Star schema got to do ?
where do we actually need to it?


THe main feature of the star schema is FACT TABLE and DIMENSION TABLES,Which allows browsing,drill down,specifying criteria.

FACT TABLE:The fact table contains the primary key madeup of Foreign keys that have migrated from all dimensions.The fact table is usually skinny and long.
Facts and Dimensions

FACTS AND DIMENSIONS


When examining how people look at data, they usually want to see some sort of aggregated data. These data are called measures or facts. These measures are numeric values that are measurable and usually additive.
For example, sales dollars are a perfect measure. Every order that comes in generates a certain sales volume measured in some currency. If your company sells 20 products in one day, each for $5 dollars, they generate 100 dollars in total sales. Therefore, sales dollars is one measure or fact most companies track. Companies may also want to know how many customers they had that day. Did 5 customers buy an average of 4 products each, or did just one customer buy 20 products? Sales dollars and customer counts are two measures businesses may want to track.

DIMENSIONS
Just tracking measures isn't enough, however. People need to look at measures using those "by" conditions. The "by" conditions are called dimensions. In order to examine sales dollars, people almost always wan to see them by day, or by quarter, or by year. There is almost always a time dimension on anything people ask for. They may also want to know sales by category or by product. These "by" conditions will map into dimensions: there is almost always a time dimension, and product and geography dimensions are very common as well.

Therefore, in designing a star schema, the first order of business is usually to determine what people want to see (the measures) and how they want to see it (the dimensions).



Reference:
Designing the Star Schema Database
Version 1.1
By Craig Utley
This is one of the best articles.

CLICK TO READ THE ARTICLE

Thursday, April 8, 2010

Things to Know before You Start with hyperion Essbase

Two key concepts you should clearly bullet into your brains else you are always HAUNTED
1.Dense
2.Sparse
Dense: The name itself refers more concentrated speaking related to the content,where the more data or matter or details exist.

Sparse: It means less concentrated or speaking related to the content,where the data may exist may not exist at all or relatively very less compared to dense matter.Speaking more technically where the data is not uniformly or smoothly distributed.

Lets say you own a International Food Supply Business,now lets say you manufacture Bread,Noodles and Rice(Its an Assumption...ok)
lets Go little ahead
Now your RICE gets sold strictly only in INDIA
and your BREAD gets sold strictly only in UNITED STATES
and NOODLES strictly only in CHINA.

Now all the above products are not sold in every country ,that define your products RICE,BREAD and NOODLES as Sparse.

Secondly you are selling all the three products in their respected countries all round the YEAR since decades.Thats not enough still u have keep the track of the records,i mean ACCOUNTS for the products or each product,whether you are making good sales,are you making a profit or loss.By using the track of the these records you can make decisions whether to increase the production of the goods in a particular country if you are making a profit else reduce the production if you are at Loss and all other related stuff like expenses,revenues....etc,.

Finally your company sells al the 3 products dring all the months(time) of the YEAR and you got maintain the ACCOUNTS for the 3 products all the time.(Weekly,monthly Quartely,yearly).So the TIME and ACCOUNTS exists for all the PRODUCTS in each COUNTRY.
You can conclude that TIME AND ACCOUNTS as DENSE DIMENSIONS.