Skip to Content
0
Former Member
Nov 14, 2012 at 02:52 PM

use time.monthnum for a calculation in scriptlogic

29 Views

Hi,

in our time dimension we have a property monthnum which is a numeric representation of the month, i.e. Jan has 1, Feb has 2 etc. I now need to use this for a calculation in script logic, I need to multiply a value entered by a user with the monthnum.

I have tried this

*WHEN ACCOUNT*IS 110000*WHEN ACCTDETAIL*IS F_100     *REC(FACTOR=FLD(TIME.MONTHNUM),ACCTDETAIL=F_110)*ENDWHEN*ENDWHEN

I have added this directly to default.lgf and also as a script on its own which is called (RUNLOGIC) from default.lgf, in both cases it returns a zero value even though account 110000 F_100 has a value and the property in the dimension also carries a numeric value.

Thanks,

Arnold