on 07-09-2014 9:50 AM
Hi All,
I have written a script logic for copying data to multiple destinations. I want to now fetch the source time which was set in context while running the logic.
After i get the time, I will copy same data to 3,6,9,12 months of next year. Which means ultimately I want to achieve the source year.
Please suggest a solution as soon as you can.
Regards,
Mayank
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
This is the DM Script I am using but I am getting an error while running the logic, Please help.
RUN_LOGIC:Dimension set:"TIME" not assigned in Data Manager
model: PAYROLL_BUDGET. Package status: ERROR
PROMPT
(SELECTINPUT,%SOURCE%,,Source Time,"%TIME_DIM%",,1)
INFO
(%EQU%,=)
TASK
(/CPMB/DEFAULT_FORMULAS_LOGIC,EQU,%EQU%
TASK
(/CPMB/DEFAULT_FORMULAS_LOGIC,SUSER,%USER%)
TASK
(/CPMB/DEFAULT_FORMULAS_LOGIC,SAPPSET,%APPSET%)
TASK
(/CPMB/DEFAULT_FORMULAS_LOGIC,SAPP,%APP%)
TASK
(/CPMB/DEFAULT_FORMULAS_LOGIC,MEMBERSELECTION,SOURCE%EQU%%SOURCE%)
TASK
(/CPMB/DEFAULT_FORMULAS_LOGIC,LOGICFILENAME,PAYROLL_NEW.LGF)
RUN_LOGIC:Dimension set:"TIME" not assigned in Data Manager
model: PAYROLL_BUDGET. Package status: ERROR
1) I am not able to use %YEAR%, I also read it somewhere but unable to use.
2) I will tell you complete scenario, may be then you can help me.
I am loading data from BI to BPC for some combination of dimensions to one dummy cost center and forecast category, then I am copying that data for same combination to all the cost centers.
Now I need to copy the same data to all the cost centers in Budget Category but this time, time would be source year+1.03, source year+1.06, .09 and.12. Which means I need to find out the source year for which the data is loading from BI ti BPC.
Assuming that year to be same year as current year I thought of using System year.
Now please help me with it.
*SELECT(%Y%, "YEAR", "TIME", "[ID] = '%YEAR%'")
*SELECT(%H%,"[ID]",HR_ACCOUNT,"[ID]<>Shift,Education_Assist")
*XDIM_MEMBERSET HR_ACCOUNT=%H%
*XDIM_MEMBERSET ENTITY AS %ENTITYLIST%=BAS(1000)
*XDIM_MEMBERSET BUDGET_VER = Final
*WHEN CURR
*IS AED
*WHEN TIME
*IS *
*WHEN ENTITY
*IS 1000_I
*WHEN DATASOURCE
*IS Pay_Plan_New
*WHEN CATEGORY
*IS Forecast
*FOR %E%=%ENTITYLIST%
*REC(EXPRESSION=%VALUE%,CATEGORY=Forecast,ENTITY=%E%,DATASOURCE=Pay_Plan_New)
*REC(EXPRESSION=%VALUE%,CATEGORY=Forecast,ENTITY=%E%,DATASOURCE=Pay_Plan_Retired)
*FOR %M%=03,06,09,12
*REC(EXPRESSION=%VALUE%,CATEGORY=Budget,TIME=TMVL(13,%Y%.%M%),ENTITY=%E%,DATASOURCE=Pay_Plan_New)
*REC(EXPRESSION=%VALUE%,CATEGORY=Budget,TIME=TMVL(13,%Y%.%M%),ENTITY=%E%,DATASOURCE=Pay_Plan_Retired)
*NEXT
*NEXT
*ENDWHEN
*ENDWHEN
*ENDWHEN
*ENDWHEN
*ENDWHEN
Yes this can be done Vadim but these packages will be scheduled to run automatically daily, so when it takes time from the context, the time in the context and the time for which data got loaded could be different, and the logic may fail.
So, will it be right to take it from context?
Is there any other way of tracking time for which data is getting loaded? I mean the time in BI.
If you want to schedule some package to run daily, then it will get TIME from context only once. In this case you don't need to get time member from context, just ask user to type year once in the PROMPT(TEXT,... and pass it using REPLACEPARAM to the script $$ variable. At the moment of year change you have to reschedule the package with the new year value...
Vadim
P.S. You can also modify RUNLOGIC_PH badi to launch script with current year parameter filled in the badi code.
Hi,
Can you more elaborate it?
Regards
Piyush
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
User | Count |
---|---|
6 | |
5 | |
2 | |
1 | |
1 | |
1 | |
1 | |
1 | |
1 | |
1 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.