turbo integrator rule
-
- Posts: 44
- Joined: Mon May 17, 2010 8:14 am
- OLAP Product: tm1 cognos
- Version: 9.5
- Excel Version: 2007
turbo integrator rule
hi,
i am new to the cognos tm1.
i am trying to create and load a cube using turbo integrator process.within that i have a requirement like the elements within the dimension should be moved dynamically based on certain conditions.the if condition i tried like below .Please
if((dayno(today)-dayno( AttrS(type,storename,'StartDate')) >365) ;
but its not working it showing some error like "syntax error :comma missing "
can anyone help me about this???
thanks and regards
angel
i am new to the cognos tm1.
i am trying to create and load a cube using turbo integrator process.within that i have a requirement like the elements within the dimension should be moved dynamically based on certain conditions.the if condition i tried like below .Please
if((dayno(today)-dayno( AttrS(type,storename,'StartDate')) >365) ;
but its not working it showing some error like "syntax error :comma missing "
can anyone help me about this???
thanks and regards
angel
-
- Posts: 13
- Joined: Mon May 17, 2010 10:10 am
- OLAP Product: TM1
- Version: 9.5
- Excel Version: 2007
Element Addition and Deletion using Rule Editor
Hi,
There is an if condition, if this condition is true then an element is to be shifted from one consolidated element to another consolidated element which is in the same dimension.
Can anyone pls tell how to do it using rule editor.
Thanks
Monisha
There is an if condition, if this condition is true then an element is to be shifted from one consolidated element to another consolidated element which is in the same dimension.
Can anyone pls tell how to do it using rule editor.
Thanks
Monisha
- 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: Element Addition and Deletion using Rule Editor
Hi Monisha,
This cannot be done in TM1, dimension structures are totally independant of the cubes (and rules) they are used in.
A way of doing this would be to do something like the following.
SourceValue contains the value you want.
ChildA is in the first consolidation
ChildB is in the second consolidation.
Your rules are
ChildA= N: If ( condition is true , SourceValue, 0);
ChildB= N: If ( condition is false, SourceValue, 0);
Feeders
SourceValue=> ChildA, ChildB;
Note that I've missed out most of the syntax!
Another way of doing this would be to handle the problem when the data is entered into the system, probably only practical if it is loaded with a TI process.
HTH
Cheers,
This cannot be done in TM1, dimension structures are totally independant of the cubes (and rules) they are used in.
A way of doing this would be to do something like the following.
SourceValue contains the value you want.
ChildA is in the first consolidation
ChildB is in the second consolidation.
Your rules are
ChildA= N: If ( condition is true , SourceValue, 0);
ChildB= N: If ( condition is false, SourceValue, 0);
Feeders
SourceValue=> ChildA, ChildB;
Note that I've missed out most of the syntax!
Another way of doing this would be to handle the problem when the data is entered into the system, probably only practical if it is loaded with a TI process.
HTH
Cheers,
Technical Director
www.infocat.co.uk
www.infocat.co.uk
- Martin Ryan
- Site Admin
- Posts: 2003
- Joined: Sat May 10, 2008 9:08 am
- OLAP Product: TM1
- Version: 10.1
- Excel Version: 2010
- Location: Wellington, New Zealand
- Contact:
Re: turbo integrator rule
Hi Angel,
I think you're missing a closing parenthesis.
if((dayno(today)-dayno( AttrS(type,storename,'StartDate'))) >365) ;
(I've also moved this post to the correct forum).
Martin
I think you're missing a closing parenthesis.
if((dayno(today)-dayno( AttrS(type,storename,'StartDate'))) >365) ;
(I've also moved this post to the correct forum).
Martin
Please do not send technical questions via private message or email. Post them in the forum where you'll probably get a faster reply, and everyone can benefit from the answers.
Jodi Ryan Family Lawyer
Jodi Ryan Family Lawyer
-
- Posts: 44
- Joined: Mon May 17, 2010 8:14 am
- OLAP Product: tm1 cognos
- Version: 9.5
- Excel Version: 2007
Re: turbo integrator rule
Thank you its worked well 

-
- Posts: 44
- Joined: Mon May 17, 2010 8:14 am
- OLAP Product: tm1 cognos
- Version: 9.5
- Excel Version: 2007
turbo integrator rule condition
hi,
I am trying to shift an element component to another hierarchy if the element start date is greater than 365 days.this condition is not working fine with me(element components were not shifting.TI process completing sucessfully) .Can any one give me suggestions over this??
if(dayno(today)-dayno( AttrS('dim_name','elementname','attributename'))>365) ;
DimensionElementcomponentDelete('dim_name','elementname','elementcomponentname');
DimensionElementcomponentAdd('dim_name','elementname','elementcomponentname',+1);
endif;
Thanks and regards,
angel
I am trying to shift an element component to another hierarchy if the element start date is greater than 365 days.this condition is not working fine with me(element components were not shifting.TI process completing sucessfully) .Can any one give me suggestions over this??
if(dayno(today)-dayno( AttrS('dim_name','elementname','attributename'))>365) ;
DimensionElementcomponentDelete('dim_name','elementname','elementcomponentname');
DimensionElementcomponentAdd('dim_name','elementname','elementcomponentname',+1);
endif;
Thanks and regards,
angel
-
- Posts: 13
- Joined: Mon May 17, 2010 10:10 am
- OLAP Product: TM1
- Version: 9.5
- Excel Version: 2007
Re: Element Addition and Deletion using Rule Editor
Hi,
Actually the description is like this:
Child A is in "New" Consloidation
No elements are there in "Old" Consolidation.
A condition is there which include substraction of start date of "A Company" And Current date. If this value is greater than 366 then Child A is to be shifted from "New" to "Old".
Regards,
Monisha
Actually the description is like this:
Child A is in "New" Consloidation
No elements are there in "Old" Consolidation.
A condition is there which include substraction of start date of "A Company" And Current date. If this value is greater than 366 then Child A is to be shifted from "New" to "Old".
Regards,
Monisha
-
- Site Admin
- Posts: 6667
- Joined: Sun May 11, 2008 2:30 am
- OLAP Product: TM1
- Version: PA2.0.9.18 Classic NO PAW!
- Excel Version: 2013 and Office 365
- Location: Sydney, Australia
- Contact:
Re: Element Addition and Deletion using Rule Editor
I haven't tested this, but I believe that it would be possible to do that with a rule by including Child A in both the New and Old consolidations, and using the ElWeight rules function to set the value for the element in the appropriate consolidation to either 0 or 1 depending on the result of the condition test. However, it's not a solution that I particularly like the idea of since it's potentially confusing for someone who is drilling down on the cube to do an ad hoc query.monishapm wrote: Actually the description is like this:
Child A is in "New" Consloidation
No elements are there in "Old" Consolidation.
A condition is there which include substraction of start date of "A Company" And Current date. If this value is greater than 366 then Child A is to be shifted from "New" to "Old".
As Steve said, rules as such can't physically move an element from one consolidation to another... but T.I. can. It can't do it in real time, but if you're only testing whether the start date is > 366 days ago you don't need to. My suggestion would be to create a "housekeeping" process that runs overnight and handles this kind of update, removing the element from the original consolidation (DimensionElementComponentDelete) and adding it to the new one (DimensionElementComponentAdd).
"To them, equipment failure is terrifying. To me, it’s 'Tuesday.' "
-----------
Before posting, please check the documentation, the FAQ, the Search function and FOR THE LOVE OF GLUB the Request Guidelines.
-----------
Before posting, please check the documentation, the FAQ, the Search function and FOR THE LOVE OF GLUB the Request Guidelines.
-
- MVP
- Posts: 3706
- Joined: Fri Mar 13, 2009 11:14 am
- OLAP Product: TableManager1
- Version: PA 2.0.x
- Excel Version: Office 365
- Location: Switzerland
Re: turbo integrator rule condition
Question 1:
Is your code really exactly as posted? It looks like you are encapsulating your variable names in single quotes, therefore they will be treated as literal strings. Strip out the single quotes or post the actual code to make trouble-shooting possible.
Question 2:
What advanced code tab are you doing this on? DimensionElementComponentAdd and DimensionElementComponentDelete should only be done on either the Prolog or Metadata.
Is your code really exactly as posted? It looks like you are encapsulating your variable names in single quotes, therefore they will be treated as literal strings. Strip out the single quotes or post the actual code to make trouble-shooting possible.
Question 2:
What advanced code tab are you doing this on? DimensionElementComponentAdd and DimensionElementComponentDelete should only be done on either the Prolog or Metadata.
-
- Posts: 44
- Joined: Mon May 17, 2010 8:14 am
- OLAP Product: tm1 cognos
- Version: 9.5
- Excel Version: 2007
Re: turbo integrator rule condition
hi,
this is my exact code..
if((dayno(today)-dayno( AttrS('storename1',type,'StartDate'))<365)) ;
DimensionElementcomponentDelete('storename1',type,storename);
DimensionElementcomponentAdd('storename1','lfl',storename,+1);
endif;
i am doing it in metadata tab.
storename1 is my dimension,type(element in store dimension) =supermarket,express,lfl(within supermarket,express ,lfl i have many stores like store1,store2... ),startdate is an attribute of the storename
Thanks and regards ,
angel
I am trying to delete an element component 'store1'(say it is in 'express' hierarchy) and trying to paste it in 'lfl' if it is opened before 1 year.
this is my exact code..
if((dayno(today)-dayno( AttrS('storename1',type,'StartDate'))<365)) ;
DimensionElementcomponentDelete('storename1',type,storename);
DimensionElementcomponentAdd('storename1','lfl',storename,+1);
endif;
i am doing it in metadata tab.
storename1 is my dimension,type(element in store dimension) =supermarket,express,lfl(within supermarket,express ,lfl i have many stores like store1,store2... ),startdate is an attribute of the storename
Thanks and regards ,
angel
I am trying to delete an element component 'store1'(say it is in 'express' hierarchy) and trying to paste it in 'lfl' if it is opened before 1 year.
-
- Community Contributor
- Posts: 139
- Joined: Mon Sep 15, 2008 1:45 pm
Re: turbo integrator rule condition
I have used the dimensionelementcomponentdelete / add combo a lot in the past and I don't see anything in your code that is obviously wrong.
=> I would start 'debugging' by inserting Asciioutputstatements. Things to check: is your attribute actually in a format that dayno evaluates correctly? That would be my first guess tbh. I.e. is there actually something passing your condition.
=> I would start 'debugging' by inserting Asciioutputstatements. Things to check: is your attribute actually in a format that dayno evaluates correctly? That would be my first guess tbh. I.e. is there actually something passing your condition.
-
- Site Admin
- Posts: 6667
- Joined: Sun May 11, 2008 2:30 am
- OLAP Product: TM1
- Version: PA2.0.9.18 Classic NO PAW!
- Excel Version: 2013 and Office 365
- Location: Sydney, Australia
- Contact:
Re: turbo integrator rule condition
Then wouldn't it be >365 rather than <365?angel1234 wrote:hi,
this is my exact code..
if((dayno(today)-dayno( AttrS('storename1',type,'StartDate'))<365)) ;
DimensionElementcomponentDelete('storename1',type,storename);
DimensionElementcomponentAdd('storename1','lfl',storename,+1);
endif;
i am doing it in metadata tab.
storename1 is my dimension,type(element in store dimension) =supermarket,express,lfl(within supermarket,express ,lfl i have many stores like store1,store2... ),startdate is an attribute of the storename
Thanks and regards ,
angel
I am trying to delete an element component 'store1'(say it is in 'express' hierarchy) and trying to paste it in 'lfl' if it is opened before 1 year.
"To them, equipment failure is terrifying. To me, it’s 'Tuesday.' "
-----------
Before posting, please check the documentation, the FAQ, the Search function and FOR THE LOVE OF GLUB the Request Guidelines.
-----------
Before posting, please check the documentation, the FAQ, the Search function and FOR THE LOVE OF GLUB the Request Guidelines.
-
- Posts: 13
- Joined: Mon May 17, 2010 10:10 am
- OLAP Product: TM1
- Version: 9.5
- Excel Version: 2007
Re: Element Addition and Deletion using Rule Editor
Hi,
I tried using TI process. But its showing error :
"StoreA","1 Quarter","France","1.",Data Source line (1) Error: MetaData procedure line (9): Unable to delete element "StoreA" from consolidation.
Pls tell why its not able to delete??
Regards,
Monisha
I tried using TI process. But its showing error :
"StoreA","1 Quarter","France","1.",Data Source line (1) Error: MetaData procedure line (9): Unable to delete element "StoreA" from consolidation.
Pls tell why its not able to delete??
Regards,
Monisha
-
- Site Admin
- Posts: 6667
- Joined: Sun May 11, 2008 2:30 am
- OLAP Product: TM1
- Version: PA2.0.9.18 Classic NO PAW!
- Excel Version: 2013 and Office 365
- Location: Sydney, Australia
- Contact:
Re: Element Addition and Deletion using Rule Editor
With that error message, it'll be because StoreA isn't part of the consolidation that you've specified. To avoid the error, use the ElIsPar function as the condition of an If() function to determine whether the element still is part of the consolidation. Only use DimensionElementComponentDelete if it is.monishapm wrote:Hi,
I tried using TI process. But its showing error :
"StoreA","1 Quarter","France","1.",Data Source line (1) Error: MetaData procedure line (9): Unable to delete element "StoreA" from consolidation.
Pls tell why its not able to delete??
Admin Note: I've merged the many and varied threads relating to this topic into one.
"To them, equipment failure is terrifying. To me, it’s 'Tuesday.' "
-----------
Before posting, please check the documentation, the FAQ, the Search function and FOR THE LOVE OF GLUB the Request Guidelines.
-----------
Before posting, please check the documentation, the FAQ, the Search function and FOR THE LOVE OF GLUB the Request Guidelines.
-
- MVP
- Posts: 3706
- Joined: Fri Mar 13, 2009 11:14 am
- OLAP Product: TableManager1
- Version: PA 2.0.x
- Excel Version: Office 365
- Location: Switzerland
Re: Element Addition and Deletion using Rule Editor
That's a relief, until I got to this line I thought I had gone mad.Alan Kirk wrote:Admin Note: I've merged the many and varied threads relating to this topic into one.
-
- Site Admin
- Posts: 6667
- Joined: Sun May 11, 2008 2:30 am
- OLAP Product: TM1
- Version: PA2.0.9.18 Classic NO PAW!
- Excel Version: 2013 and Office 365
- Location: Sydney, Australia
- Contact:
Re: Element Addition and Deletion using Rule Editor
Yes, there's little more irritating than to spend the time answering a question, only to find that someone else has answered it when it was asked in a slightly different way two threads down. Better to merge the relevant posts to cut that possibility off at the pass.lotsaram wrote:That's a relief, until I got to this line I thought I had gone mad.Alan Kirk wrote:Admin Note: I've merged the many and varied threads relating to this topic into one.
"To them, equipment failure is terrifying. To me, it’s 'Tuesday.' "
-----------
Before posting, please check the documentation, the FAQ, the Search function and FOR THE LOVE OF GLUB the Request Guidelines.
-----------
Before posting, please check the documentation, the FAQ, the Search function and FOR THE LOVE OF GLUB the Request Guidelines.
-
- Posts: 44
- Joined: Mon May 17, 2010 8:14 am
- OLAP Product: tm1 cognos
- Version: 9.5
- Excel Version: 2007
Re: turbo integrator rule
hi alan,
but we are trying to implement it in different ways.
thanks and regards,
angel
but we are trying to implement it in different ways.

thanks and regards,
angel
-
- Posts: 44
- Joined: Mon May 17, 2010 8:14 am
- OLAP Product: tm1 cognos
- Version: 9.5
- Excel Version: 2007
Re: turbo integrator rule
hi lotsaram,,
i didnt get you what you told about debugging can you please explain me how to do debugging over that.
since my process is compliing sucessfully i am not able to continue the debubbing.
Thanks and regards,
angel
i didnt get you what you told about debugging can you please explain me how to do debugging over that.
since my process is compliing sucessfully i am not able to continue the debubbing.
Thanks and regards,
angel
-
- Site Admin
- Posts: 6667
- Joined: Sun May 11, 2008 2:30 am
- OLAP Product: TM1
- Version: PA2.0.9.18 Classic NO PAW!
- Excel Version: 2013 and Office 365
- Location: Sydney, Australia
- Contact:
Re: turbo integrator rule
That was Jeroen, not Lotsaram.angel1234 wrote:hi lotsaram,,
i didnt get you what you told about debugging can you please explain me how to do debugging over that.
since my process is compliing sucessfully i am not able to continue the debubbing.
TI doesn't have a debugging system as such, so you fudge it by doing AsciiOutputs of your variable values to check that they really are what you think they are. In this case it would involve outputting the result of the expression dayno( AttrS('storename1',type,'StartDate')) to a text file to ensure that it's really yielding the value that you think it is. (Note that you'll need to convert it to a string first.) As I said in my post, though, I suspect that your main problem is that your comparison operator is the wrong way around.
"To them, equipment failure is terrifying. To me, it’s 'Tuesday.' "
-----------
Before posting, please check the documentation, the FAQ, the Search function and FOR THE LOVE OF GLUB the Request Guidelines.
-----------
Before posting, please check the documentation, the FAQ, the Search function and FOR THE LOVE OF GLUB the Request Guidelines.
-
- Posts: 44
- Joined: Mon May 17, 2010 8:14 am
- OLAP Product: tm1 cognos
- Version: 9.5
- Excel Version: 2007
Re: turbo integrator rule
hi,
can you please tell me is this the correct syntax of ascii output statement??
asciioutput('F:outputext.txt',dayno(attrs('storename1',type,'startdate');
and please tell me in which tab i should write the statement in advanced area.
thanks and regards,
angel
can you please tell me is this the correct syntax of ascii output statement??
asciioutput('F:outputext.txt',dayno(attrs('storename1',type,'startdate');
and please tell me in which tab i should write the statement in advanced area.
thanks and regards,
angel