Setting hierarchy of different hierarchies within 1 dimensio

Post Reply
telula
Posts: 99
Joined: Tue Nov 18, 2008 5:40 am

Setting hierarchy of different hierarchies within 1 dimensio

Post by telula »

Hello,
I have 2 separate sets of hierarchies in 1 dimension
For this hierarchy, I want it arranged by input.
-All Items
+Software
+Hardware
+Other

For the hierachy below, I want it arranged by name
-All Hardware
+desktop
+laptop
+printers

However,dimensionsortorder cannot identify the 2 sets to apply different sorting order. Is there a workaround ?
User avatar
Steve Rowe
Site Admin
Posts: 2455
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: Setting hierarchy of different hierarchies within 1 dimensio

Post by Steve Rowe »

No there's no way to do this, the only thing you can do is manipulate the base element names so an alphabetical setting to the dimension sort order gives the correct ordering.
Technical Director
www.infocat.co.uk
User avatar
wissew
Posts: 54
Joined: Tue Jun 17, 2008 7:24 pm
OLAP Product: TM1
Version: 9.5.2; 10.2.2; 11
Excel Version: 2003 SP3 - 2013
Location: Beaverton, OR

Re: Setting hierarchy of different hierarchies within 1 dimensio

Post by wissew »

I won't be too quick to shot this down. What is the data source for your hiearchy? Hopefully it is external and sql can be used to resort upon input. Your first pass will load and read the hiearchy via your first order. When loading the second adjust the sort order in the sql statement to read the hierarchy to confirm to the second order and set your dimension sort order in TI to load the hierarchy as it is read on input.
telula
Posts: 99
Joined: Tue Nov 18, 2008 5:40 am

Re: Setting hierarchy of different hierarchies within 1 dimensio

Post by telula »

Hello,
But when you do dimension sort order, it doesnt identify hierarchies.Do you mind showing me the TI code to do what you just said?
kangkc
Community Contributor
Posts: 206
Joined: Fri Oct 17, 2008 2:40 am
OLAP Product: TM1, PA , TMVGate
Version: 2.x
Excel Version: 36x
Location: Singapore
Contact:

Re: Setting hierarchy of different hierarchies within 1 dimensio

Post by kangkc »

Er.....I'll do it via subset for specific requirement on order. It's too tedious to play around with indexes which can be easily re-arrange via subset.
User avatar
wissew
Posts: 54
Joined: Tue Jun 17, 2008 7:24 pm
OLAP Product: TM1
Version: 9.5.2; 10.2.2; 11
Excel Version: 2003 SP3 - 2013
Location: Beaverton, OR

Re: Setting hierarchy of different hierarchies within 1 dimensio

Post by wissew »

telula wrote:Hello,
But when you do dimension sort order, it doesnt identify hierarchies.Do you mind showing me the TI code to do what you just said?

The first TI porcess specities this sort order
DIMENSIONSORTORDER(DimName,'ByName','DESCENDING','ByHierarchy','ASCENDING');

Second process:
DIMENSIONSORTORDER(DimName,'ByInput','DESCENDING','ByInput','ASCENDING');

After you map the elements, parents and attributes you need to copy the code from the generated statement to below the line on the metadata and data tabs and then change the contents column on the variable tab to OTHER. At this point the dimansion sort order statements are removed from the prolog tab and all updates in the chore will take the last sort order statement used. Running the chore in batch mode will help.
Post Reply