This is a guest post from Revelwood’s Susan Musselman.
Did you know you can easily reset cube logging in TM1? A previous tech tip was written to discuss when to enable and disable logging. As stated in that posting, it is best practice to turn cube logging off while processing TurboIntegrator processes. Typically, logging is turned off in the Prolog and turned back on in the Epilog. But if an error occurs when the process is run, it never reaches the Epilog and logging never gets turned back on.
Initially, logging is set by right-clicking on cubes and placing a check in the logging box for each cube that needs logging turned on.
When logging is turned off via TI process, the checkbox is turned off.
One way to ensure that settings aren’t permanently “lost” is to reset logging in a chore that runs on a regular schedule (nightly or more frequently, if desired). To do this, set up an attribute in the }Cubes dimension to define which cubes should have logging turned on and manually populate the attribute with “YES” for each cube that should be turned on for logging. In the following example, the attribute is called “LogChore” and two cubes are defined to have logging enabled.
Then create a process with “None” as the source that will loop through the cubes and set log changes to 1 when the attribute is populated. Here is the code to put in the Prolog tab.
iCount = 0 ;
iSize = DIMSIZ ( ‘}Cubes’ ) ;
WHILE ( iCount < iSize ) ;
iCount = iCount + 1 ;
strElement = DIMNM ( ‘}Cubes’ , iCount ) ;
IF ( SUBST ( ATTRS ( ‘}Cubes’ , strElement , ‘LogChore’ ) , 1 , 1 ) @= ‘Y’ ) ;
CUBESETLOGCHANGES ( strElement , 1 ) ;
The final step is to set the process up as a chore and schedule it to run nightly. Any cubes that may have accidentally had Logging turned off will be turned back on.
IBM Planning Analytics is full of new features and functionality. Not sure where to start? Our team here at Revelwood can help. Contact us for more information at firstname.lastname@example.org. And stay tuned for more Planning Analytics Tips & Tricks weekly in our Knowledge Center and in upcoming newsletters!