Page 1 of 1

Deleting history in TM1 Cube

Posted: Mon Aug 05, 2013 6:10 pm
by vins
Hi experts,

Kindly let me know how to delete history of records in TM1 Cube using TI process?

Thanks

Re: Deleting history in TM1 Cube

Posted: Mon Aug 05, 2013 6:19 pm
by Wim Gielis
You will need the

Code: Select all

ViewZeroOut 
function, applied to a view on a cube. Use the

Code: Select all

ViewCreate
function, and a bunch of other functions.
Most probably, the view creation has been scripted in the same process, but that's not needed.
It could even be a view that you save manually in the cube viewer (it's also possible to clear the data manually in the cube viewer).

Re: Deleting history in TM1 Cube

Posted: Tue Aug 06, 2013 5:09 am
by EvgenyT
Simple example along these lines:

# Create View
sView = cTI|NumberToString(Rand*Rand);

IF( ViewExists( cubDestination, sView ) = 1 );
ViewDestroy( cubDestination, sView );
ENDIF;

ViewCreate( cubDestination, sView );

ViewZeroOut( cubDestination, sView );

Obviously you will have to create subsets for dimension with elements you want to clear e.g. Jun 2013 Budget data..

Check out this link with all Subset function:

http://pic.dhe.ibm.com/infocenter/ctm1/v9r5m0/index.jsp

Try to write a simple ZeroOut process and when you get stuck let us now.

Thanks

ET

Re: Deleting history in TM1 Cube

Posted: Sun Aug 11, 2013 5:32 am
by vins
@EvgenyT : Thanks a ton.. I was able to achieve my requirement.

Re: Deleting history in TM1 Cube

Posted: Mon Aug 12, 2013 5:46 am
by EvgenyT
You are welcome ;)