Solved

10777: Designing a Data Warehouse: Dimension table indexes:

Posted on 2014-11-05
3
254 Views
Last Modified: 2014-11-06
Hi experts:

i am reading about Dimension table indexes, but i do not understand
1. Create a nonclustered primary key index
2. Create a clustered business key index

I can show you an example of each
0
Comment
Question by:enrique_aeo
3 Comments
 
LVL 24

Expert Comment

by:Phillip Burton
Comment Utility
Please do.
0
 

Author Comment

by:enrique_aeo
Comment Utility
The code if it is,
I do not understand is the concept, which means that the difference.
When to use one or the other?
0
 
LVL 3

Accepted Solution

by:
smilieface earned 500 total points
Comment Utility
The difference between non-clustered and clustered indexes is well documented elsewhere. However in brief the answers to this might be:

A Primary Key is unique, and for something like a data warehouse dimension table where you have "generational" data (changes to the record are written as a new record, and the old record is retained) we often see a "surrogate key" used. The "natural" keys (such as Customer Id will be repeated on generations of data

The clustered index doesn't have to be unique, but defines where the data is stored, as it is a sorted index. This will mean that other strategies, such as storing all the data updated on a specific date together, can be explored. This would enable faster reporting if the report is based on dates.

Essentially, the clustered index is the one you WANT to use for data retrieval. The Primary Key is just a Unique index.
0

Featured Post

Find Ransomware Secrets With All-Source Analysis

Ransomware has become a major concern for organizations; its prevalence has grown due to past successes achieved by threat actors. While each ransomware variant is different, we’ve seen some common tactics and trends used among the authors of the malware.

Join & Write a Comment

This post first appeared at Oracleinaction  (http://oracleinaction.com/undo-and-redo-in-oracle/)by Anju Garg (Myself). I  will demonstrate that undo for DML’s is stored both in undo tablespace and online redo logs. Then, we will analyze the reaso…
In this article I will describe the Detach & Attach method as one possible migration process and I will add the extra tasks needed for an upgrade when and where is applied so it will cover all.
This video shows how to Export data from an Oracle database using the Datapump Export Utility.  The corresponding Datapump Import utility is also discussed and demonstrated.
Using examples as well as descriptions, and references to Books Online, show the documentation available for datatypes, explain the available data types and show how data can be passed into and out of variables.

763 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

15 Experts available now in Live!

Get 1:1 Help Now