cancel
Showing results for 
Search instead for 
Did you mean: 

Transfer Periodic Data from YTD model to periodic Model

Former Member
0 Kudos

Hi Experts,

I have a requirement to transfer Periodic Values from a YTD model to a Periodic Model.

The approach I am taking is first Copy the Periodic Values within the YTD application itself to dummy Audittrail Member and then Using destination app to transfer the data from this Audittrail member to Periodic Model.

I have a written the below  script for calculating and posting the Periodic Values to a dummy Audittrail member:

*XDIM_MEMBERSET ENTITY= %ENTITY_SET%

*XDIM_MEMBERSET TIME= %TIME_SET%,TMVL(-1,%TIME_SET%)

*WHEN TIME

*IS %TIME_SET%

*REC(FACTOR=1,AUDITTRAIL="AUDIT TRAIL TO CAPTURE PERIODIC VALUES")

*IS TMVL(-1,%TIME_SET%)

*REC(FACTOR=-1,AUDITTRAIL="AUDIT TRAIL TO CAPTURE PERIODIC VALUES" ,TIME=%TIME_SET%)

*ENDWHEN

*ENDWHEN

This script is running fine for months from Feb- Dec.

I am facing an issue when running for January. The following message appears in the Data manager package: RUN_LOGIC:Invalid TMVL return value

Is there any way to prevent the system from analyzing TMVL(-1,%TIME_SET%) if January is selected as the %TIME_SET%?

Warm Regards,

Collin.

Accepted Solutions (0)

Answers (1)

Answers (1)

former_member186338
Active Contributor
0 Kudos

Hi Collin,

"Is there any way to prevent the system from analyzing TMVL(-1,%TIME_SET%) if January is selected as the %TIME_SET%?"

TMVL is the function that return the base member shifted by the first argument of TMVL function. The sequence of members is sorted based on the TIMEID value. Please ensure that you have previous year DEC value with correct TIMEID.

Vadim

P.S. What was the idea behind to use member ID's with spaces inside "AUDIT TRAIL TO CAPTURE PERIODIC VALUES"??? A lot of script logic errors may be due to the strange naming...

Former Member
0 Kudos

Hi Vadim,

I actually realized later I was getting the error "RUN_LOGIC:Invalid TMVL return value"  because I was running the script on 2006.01. Since my TIME dimension starts 2006.01 (i.e. I do not have a member 2015.12 in my Time Dimension Member) 

When I ran for 2007.01 there was no problem.

My main requirement with the script was that when running it for Jan of any year it should not calculate Jan current year - Dec previous year.

After doing some R&D on SCN I found out a solution as below:

*WHEN TIME

*IS %TIME_SET%

*REC(FACTOR=1,TIME=%TIME_SET%)

*IS TMVL(-1,%TIME_SET%)

*WHEN TIME.MONTHNUM

*IS  "12"

*ELSE

*REC(FACTOR=-1,TIME=%TIME_SET%)

*ENDWHEN

*ENDWHEN

The ID "AUDIT TRAIL TO CAPTURE PERIODIC VALUES" is just illustrative.

Thanks and Regards,

Collin.

former_member186338
Active Contributor
0 Kudos

"I actually realized later I was getting the error "RUN_LOGIC:Invalid TMVL return value"  because I was running the script on 2006.01. Since my TIME dimension starts 2006.01" - yes, my previous answer was "Please ensure that you have previous year DEC..."

To skip subtraction of DEC your code is correct!

Vadim