Consolidation element not found

Post Reply
Kazêh
Posts: 44
Joined: Fri Apr 19, 2013 12:59 pm
OLAP Product: TM1
Version: 10.1
Excel Version: 2007

Consolidation element not found

Post by Kazêh »

Hi guys, a silly question about how to create a dimension with turbo integrator.

i have the follow data in csv file

Total
A Total
B Total
C Total
D Total
X
Y
Z

when you create the dimension with TI, you select the first colum as element and the second as consolidation, but it trhows you a warning that X, Y and Z can't find a consolidation element.
the dimension is created as i want, but i want the turbo integrator to execute perfectly, is there anyway to do it? without adding an Aux element that consolidate x,y,z? and of course , not adding elements manually

Thanks
User avatar
jim wood
Site Admin
Posts: 3958
Joined: Wed May 14, 2008 1:51 pm
OLAP Product: TM1
Version: PA 2.0.7
Excel Version: Office 365
Location: 37 East 18th Street New York
Contact:

Re: Consolidation element not found

Post by jim wood »

Take the script generated, copy and paste somewhere else within the same tab, set all variables to other and then add an if statement to the part that creates the consolidation relationship to do a check for a consolidated element. Short I know but it's the way to do it.
Struggling through the quagmire of life to reach the other side of who knows where.
Shop at Amazon
Jimbo PC Builds on YouTube
OS: Mac OS 11 PA Version: 2.0.7
Kazêh
Posts: 44
Joined: Fri Apr 19, 2013 12:59 pm
OLAP Product: TM1
Version: 10.1
Excel Version: 2007

Re: Consolidation element not found

Post by Kazêh »

Jim, thanks for the reply.
here i have the codes generated

Code: Select all

Prolog

DIMENSIONDELETEALLELEMENTS('Ramo test prueba');
DIMENSIONSORTORDER('Ramo test prueba','BYINPUT','ASCENDING','BYINPUT','ASCENDING');

Code: Select all


DIMENSIONELEMENTINSERT('Ramo test prueba','',Ramo,'n');
DIMENSIONELEMENTINSERT('Ramo test prueba','',Padre,'c');
DIMENSIONELEMENTCOMPONENTADD('Ramo test prueba',Padre,Ramo,1.000000);

that's the code generate for the TI..and the validiation should be something like this?


Code: Select all

Metadata

dimname='Ramo Test prueba';
count=DIMSIZ(dinname);
x=count;


WHILE( x >= 1 );

                element= DIMNM(dinname,x);
IF(DTYPE(dimname,element)@='C');
 (whatshouldiputhere..)
ENDIF;

   x = x - 1;

END;


i saw that code for eliminate the C elements from a dimension, i thogh this migh be something similar..but i dont know what should i  put after the dtype.
if is it posible, can you show me the standard code for doind this kind of thing? it doesnt have to apply to my example, i just i dont normaly create scripts in TI.

Thanks for any tips.
BariAbdul
Regular Participant
Posts: 424
Joined: Sat Mar 10, 2012 1:03 pm
OLAP Product: IBM TM1, Planning Analytics, P
Version: PAW 2.0.8
Excel Version: 2019

Re: Consolidation element not found

Post by BariAbdul »

Are you trying to create dimension or unwinding existing dimension hierarchy,Because the code you provide break parent child relationship.Thanks
"You Never Fail Until You Stop Trying......"
Kazêh
Posts: 44
Joined: Fri Apr 19, 2013 12:59 pm
OLAP Product: TM1
Version: 10.1
Excel Version: 2007

Re: Consolidation element not found

Post by Kazêh »

Creating dimension, as i said, i saw that code and i tho it migh help me to create the dimension without the warnings.
User avatar
jim wood
Site Admin
Posts: 3958
Joined: Wed May 14, 2008 1:51 pm
OLAP Product: TM1
Version: PA 2.0.7
Excel Version: Office 365
Location: 37 East 18th Street New York
Contact:

Re: Consolidation element not found

Post by jim wood »

This is more what I was eluding to earlier (regardless of whether you recreating or not)

Code: Select all

DIMENSIONELEMENTINSERT('Ramo test prueba','',Ramo,'n');
IF(Padre@<>'');
    DIMENSIONELEMENTINSERT('Ramo test prueba','',Padre,'c');
    DIMENSIONELEMENTCOMPONENTADD('Ramo test prueba',Padre,Ramo,1.000000);
EndIF;
Struggling through the quagmire of life to reach the other side of who knows where.
Shop at Amazon
Jimbo PC Builds on YouTube
OS: Mac OS 11 PA Version: 2.0.7
Kazêh
Posts: 44
Joined: Fri Apr 19, 2013 12:59 pm
OLAP Product: TM1
Version: 10.1
Excel Version: 2007

Re: Consolidation element not found

Post by Kazêh »

thank you Jim, sorry to trouble you
tomok
MVP
Posts: 2836
Joined: Tue Feb 16, 2010 2:39 pm
OLAP Product: TM1, Palo
Version: Beginning of time thru 10.2
Excel Version: 2003-2007-2010-2013
Location: Atlanta, GA
Contact:

Re: Consolidation element not found

Post by tomok »

Your problem is due to shortcomings in the TI Wizard. When you have a two-column source, like the one you showed, the wizard will add the element in column A and then make it a parent of the element in column B. If the element in column B does not exist then you will get an error. Since the element "Total" is never in column A, it never get's created and trying to add a child to a non-existent element results in an error. Simple fix is to add this code to the Prolog tab:

Code: Select all

DimensionElementAdd('Ramo Test prueba','Total',1);
Tom O'Kelley - Manager Finance Systems
American Tower
http://www.onlinecourtreservations.com/
User avatar
jim wood
Site Admin
Posts: 3958
Joined: Wed May 14, 2008 1:51 pm
OLAP Product: TM1
Version: PA 2.0.7
Excel Version: Office 365
Location: 37 East 18th Street New York
Contact:

Re: Consolidation element not found

Post by jim wood »

tomok wrote:Your problem is due to shortcomings in the TI Wizard. When you have a two-column source, like the one you showed, the wizard will add the element in column A and then make it a parent of the element in column B. If the element in column B does not exist then you will get an error. Since the element "Total" is never in column A, it never get's created and trying to add a child to a non-existent element results in an error. Simple fix is to add this code to the Prolog tab:

Code: Select all

DimensionElementAdd('Ramo Test prueba','Total',1);
Tomok I think you'll find that Total is in column A in his quick example. It's the first line. Hence there was no need to go down this route. That's why I suggested keeping it simple. :D

Just to clarify:
Kazêh wrote: Total
A Total
B Total
C Total
D Total
X
Y
Z
Struggling through the quagmire of life to reach the other side of who knows where.
Shop at Amazon
Jimbo PC Builds on YouTube
OS: Mac OS 11 PA Version: 2.0.7
User avatar
jim wood
Site Admin
Posts: 3958
Joined: Wed May 14, 2008 1:51 pm
OLAP Product: TM1
Version: PA 2.0.7
Excel Version: Office 365
Location: 37 East 18th Street New York
Contact:

Re: Consolidation element not found

Post by jim wood »

Kazêh wrote:thank you Jim, sorry to trouble you
No bother at all. I hope it works for you,

Jim.
Struggling through the quagmire of life to reach the other side of who knows where.
Shop at Amazon
Jimbo PC Builds on YouTube
OS: Mac OS 11 PA Version: 2.0.7
Post Reply