Hi,
I am facing a problem while creating an unbalanced hierarchy dimension.
Please find attached input file format and the dimension created out of this file. Five variables given in the variable tab and I am checking condition for each variable.
I am using a TI process to crate this dimension and the Metadata script I have written is:
IF (Variable5 @<> '');
DIMENSIONELEMENTINSERT('Sample PnL','',Variable1,'c');
DIMENSIONELEMENTINSERT('Sample PnL','',Variable2,'c');
DIMENSIONELEMENTINSERT('Sample PnL','',Variable3,'c');
DIMENSIONELEMENTINSERT('Sample PnL','',Variable4,'c');
DIMENSIONELEMENTINSERT('Sample PnL','',Variable5,'n');
DIMENSIONELEMENTCOMPONENTADD('Sample PnL',Variable1,Variable2,1.000000);
DIMENSIONELEMENTCOMPONENTADD('Sample PnL',Variable2,Variable3,1.000000);
DIMENSIONELEMENTCOMPONENTADD('Sample PnL',Variable3,Variable4,1.000000);
DIMENSIONELEMENTCOMPONENTADD('Sample PnL',Variable4,Variable5,1.000000);
ELSEIF (Variable4 @<> '');
DIMENSIONELEMENTINSERT('Sample PnL','',Variable1,'c');
DIMENSIONELEMENTINSERT('Sample PnL','',Variable2,'c');
DIMENSIONELEMENTINSERT('Sample PnL','',Variable3,'c');
DIMENSIONELEMENTINSERT('Sample PnL','',Variable4,'n');
DIMENSIONELEMENTCOMPONENTADD('Sample PnL',Variable1,Variable2,1.000000);
DIMENSIONELEMENTCOMPONENTADD('Sample PnL',Variable2,Variable3,1.000000);
DIMENSIONELEMENTCOMPONENTADD('Sample PnL',Variable3,Variable4,1.000000);
ELSEIF (Variable3 @<> '');
DIMENSIONELEMENTINSERT('Sample PnL','',Variable1,'c');
DIMENSIONELEMENTINSERT('Sample PnL','',Variable2,'c');
DIMENSIONELEMENTINSERT('Sample PnL','',Variable3,'n');
DIMENSIONELEMENTCOMPONENTADD('Sample PnL',Variable1,Variable2,1.000000);
DIMENSIONELEMENTCOMPONENTADD('Sample PnL',Variable2,Variable3,1.000000);
ELSEIF (Variable2 @<> '');
DIMENSIONELEMENTINSERT('Sample PnL','',Variable1,'c');
DIMENSIONELEMENTINSERT('Sample PnL','',Variable2,'n');
DIMENSIONELEMENTCOMPONENTADD('Sample PnL',Variable1,Variable2,1.000000);
ELSE;
DIMENSIONELEMENTINSERT('Sample PnL','',Variable1,'n');
ENDIF;
Problem:The Hierarchy given in the file and the hierarchy created in the dimension are different. TRAV & ENT element is in both consolidation 9007 & 9008, and only one element in TRAV & ENT under 9007 consolidation but it include 9008 TRAV & ENT elements also. Do I need to add / modify any coding?
Please Help.
Thanks
kkmk
Issue Creating Unbalanced Hierarchy
-
- Posts: 73
- Joined: Wed Jan 25, 2012 9:08 am
- OLAP Product: IBM Cognos TM1
- Version: 10.2
- Excel Version: 2013
Issue Creating Unbalanced Hierarchy
- Attachments
-
- input file csv format
- error2.jpg (79.38 KiB) Viewed 3255 times
-
- dimension
- error1.jpg (161.82 KiB) Viewed 3255 times
-
- MVP
- Posts: 1831
- Joined: Mon Dec 05, 2011 11:51 am
- OLAP Product: Cognos TM1
- Version: PA2.0 and most of the old ones
- Excel Version: All of em
- Location: Manchester, United Kingdom
- Contact:
Re: Issue Creating Unbalanced Hierarchy
Either change it so its unique (e.g. v4 | ' - ' | v5 ) or looking at that file possibly just insert v5 straight under v3 and stick v4 in as an attribute.
Without knowing your account structure I can't really say what is the correct thing to do but your TI is doing exactly what you are telling it to.
BTW I am assuming that V1 is the left most column through to v5 on the right...
Without knowing your account structure I can't really say what is the correct thing to do but your TI is doing exactly what you are telling it to.
BTW I am assuming that V1 is the left most column through to v5 on the right...
Declan Rodger
- Steve Rowe
- Site Admin
- Posts: 2464
- Joined: Wed May 14, 2008 4:25 pm
- OLAP Product: TM1
- Version: TM1 v6,v7,v8,v9,v10,v11+PAW
- Excel Version: Nearly all of them
Re: Issue Creating Unbalanced Hierarchy
This might be better served by two dimensions?
Aren't the 9000 codes cost centres / departments / profit centres of some kind and then Trav & Ent and 600000 and so on your account structure.
As declanr said, your TI is doing what you told it to but you need to figure out what your account structure and dimensionality is.
In general I normally try and split the account struture into many dimensions as it usually enhances the utility of the cube.
Cheers
Aren't the 9000 codes cost centres / departments / profit centres of some kind and then Trav & Ent and 600000 and so on your account structure.
As declanr said, your TI is doing what you told it to but you need to figure out what your account structure and dimensionality is.
In general I normally try and split the account struture into many dimensions as it usually enhances the utility of the cube.
Cheers
Technical Director
www.infocat.co.uk
www.infocat.co.uk