Page 1 of 1

TI Process Doubling Elements?

Posted: Tue Sep 12, 2017 10:59 pm
by Thurston Howell III
My TI process tests as to whether or not an element exists and adds it to a rollup if it does not. This part it does fine, but it is also determining some extant elements do not exist and adding them again, giving me duplicates. From my code I cannot see anything wrong. I tried a ProcessQuit to determine if the DIMIX test was the error and it was.

Any ideas? Any help would be much appreciated.

Code: Select all

[IF ( DIMIX ( vCostCenter , 'cdmCostCenter' ) = 0 );
ENDIF;
   DIMENSIONELEMENTINSERT ( 'cdmCostCenter' , '' , vCostCenter , 'N');
     DIMENSIONELEMENTCOMPONENTADD ( 'cdmCostCenter' , 'CDM' , vCostCenter , 1 );
ENDIF;

Re: TI Process Doubling Elements?

Posted: Tue Sep 12, 2017 11:39 pm
by tomok
You might want to check the order of your parameters in your DIMIX. Lovey's not going to be too happy.

Re: TI Process Doubling Elements?

Posted: Wed Sep 13, 2017 9:58 am
by Steve Rowe
You might want to double check what is happening is not just an issue with the way you are looking at the dimension or give some more detail.

You can't have an element in a single consolidation more than once, do you mean that the extant elements exist in their original location and in the CDM one.

Suggest you post your whole script, are you for example using DImensionDeleteAllELements to refresh the hierarchy?

Re: TI Process Doubling Elements?

Posted: Wed Sep 13, 2017 11:35 am
by lotsaram
tomok wrote:
Tue Sep 12, 2017 11:39 pm
You might want to check the order of your parameters in your DIMIX. Lovey's not going to be too happy.
2nd that. Your DIMIX as written will return 0 100% of the time.
Steve Rowe wrote:
Wed Sep 13, 2017 9:58 am
You can't have an element in a single consolidation more than once, do you mean that the extant elements exist in their original location and in the CDM one.
and 2nd that as well. It doesn't matter if you do DimensionElementComponentAdd once or 10 thousand times, the element will only be added to the consolidation once.

Re: TI Process Doubling Elements?

Posted: Wed Sep 13, 2017 2:14 pm
by Thurston Howell III
Thanks for the feedback, everyone. Every element in the dimension exists in the rollup called CDM.

I can't believe it was just the order in DIMIX. :roll:

Lovey is NOT happy with her Thurston.