Oracle Consulting Oracle Training Oracle Support Development
Home
Catalog
Oracle Books
SQL Server Books
IT Books
Job Interview Books
eBooks
Rampant Horse Books
911 Series
Pedagogue Books

Oracle Software
image
Write for Rampant
Publish with Rampant
Rampant News
Rampant Authors
Rampant Staff
 Phone
 800-766-1884
Oracle News
Oracle Forum
Oracle Tips
Articles by our Authors
Press Releases
SQL Server Books
image
image

Oracle 11g Books

Oracle tuning

Oracle training

Oracle support

Remote Oracle

STATSPACK Viewer

Privacy Policy

 

   
 

Drop Dimension Components



Oracle Tips by Burleson

Oracle 10g Drop Dimension Components

Dropping dimension attribute columns used to be a bit cumbersome, especially if the columns had multiple attributes. Dropping one of the attributes was not possible without affecting the other attributes.

To illustrate further, the 'attribute' clause of the 'create dimension' statement allows the user to specify one or multiple columns that are uniquely determined by a hierarchy level. As seen in the example below,

CREATE DIMENSION product_dim
prod_id IS (products.prod_id)
ATTRIBUTE prod_id DETERMINES prod_name, prod_status;

Give a working example- LEVEL clause is missing and you should add parenthesis

The hierarchy level prod_id determines the attributes prod_name and prod_status. In order to drop one of the attributes, we had to drop the hierarchy level with all the attributes.

Oracle 10g introduces a new syntax for both create dimension and alter dimensions statements. It allows you to give a general name to your attribute, and further specify multiple attribute level clauses.

Let us look at an example,

CREATE DIMENSION product_dim
LEVEL prod_id IS (products.prod_id)
ATTRIBUTE att
LEVEL prod_id DETERMINES prod_name, prod_status; parenthesis are missing

In order to drop one of the attribute columns, use the statement,

ALTER DIMENSION
   product_dim
DROP ATTRIBUTE
   att
LEVEL
   prod_id
COLUMN
    prod_status;

As seen above, when you want to drop column prod_status, keeping the prod_name column, you can use the new syntax to facilitate and ease administration.

Linux Oracle commands syntax poster

ION Oracle tuning software

Oracle data dictionary reference poster



Oracle Forum

BC Oracle consulting support training

BC remote Oracle DBA   

 

   

 Copyright Š 1996 -2016 by Burleson. All rights reserved.


OracleŽ is the registered trademark of Oracle Corporation. SQL ServerŽ is the registered trademark of Microsoft Corporation. 
Many of the designations used by computer vendors to distinguish their products are claimed as Trademarks