on 01-22-2014 5:51 PM
We have a BPC NW v10 environment with a CONSOL (YTD) model and a PLANNING (Periodic) model. We have written script logic in the CONSOL model that will push actuals data (consols/elims/journals) for a specific time period (as selected by the user) to the PLANNING application. When we invoke the logic via a DM pkg in CONSOL, all works as expected, pushed data is present in the PLANNING model.
The requirement is to be able to PULL this data from PLANNING model so we setup the RUNLOGIC_PH custom function in SAP GUI; created a BADi that utilizes the RUNLOGIC_PH and will call the PushLogic we had successfully tested out in CONSOL; this pull functionality is initiated via a custom DM pkg we created in the PLANNING model (user selects a specific PLAN_TIME member in the DM pkg for the data to be pulled).
When we run the custom DM pkg in PLANNING that utilizes the BADi/RUNLOGIC_PH calling the Pushlogic in CONSOL model, the pkg run/completes successfully, correct records are generated & it states they were written successfully but we do not see the data that was to be pushed in the PLANNING model.
I went into SAP GUI using t-code UJFS and downloaded the log file from the pkg run in the CONSOL model; the log file shows the correct records generated (values, dimensionality, etc. all is correct) and it states it successfully wrote the records but they are no where to be found in the PLANNING model.
I'm attaching the logfile from the DM PKG run in the PLANNING model (i.e., calling the BADi/RUNLOGIC_PH), the pushlogic we use in the CONSOL model; and the BADi script we use in the PLANNING model for your referencing.
Any assistance on why we are not seeing the pushed data in the PLANNING model is much appreciated.
Hi Joyce,
Quick test! I see the line in LGF with RUNLOGIC_PH badi:
APPSET = QEP_BPC
Is it the correct APPSET? If you have multiple appset copies and have not changed this line - then the script will be launched in a different appset/environment.
It's better to remove this line at all, in this case current appset will be used!
Also I have some questions about PUSHTOPLAN.LGF but later (sign reverse is not required for BPC 10)
B.R. Vadim
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Yes, QEP_BPC is the correct appSet. If I remove the APP param from the BADi, the same results occur (it runs successfully but records not seen in PLANNING); additionally, when I take this APP param out, now there is no log file in the CONSOL model post the run (if the param is in there, there is a log file in CONSOL post the dm pkg run).
The PUSHTOPLAN.LGF is fine, it all works as expected. I'm not reversing signs, I'm pushing data form a YTD model to a PERIODIC model, so I have to calculate the periodic value (i.e., I'm taking the current period YTD value and subtracting the prior period YTD value to get the periodic value to push (the neg sign is on the prior periods YTD value).
Any other recommendations to try?
Thanks - Joyce
In regards to TIME & BADi:
In the PLANNING (periodic) model, the time dimension is PLAN_TIME
In the CONSOL (YTD) model, the time dimension is TIME
You'll see the *REPLACE_DIM re: these 2-dims in the actual push logic
The user initiates the dm pkg in PLANNING indicating a single PLAN_TIME member (this is passed via %PLAN_TIME_SET%), but to get the BADi to invoke the logic and pass this Plan_Time member, we have to specific the time dims from both models in the BADi:
DIMENSION PLAN_TIME = <NONE> (as this dim isn't in CONSOL)
DIMENSION TIME = <ALL> (as the time will get rescoped in the actual pushlogic with the
*XDIM_MEMBERSET TIME = %TIME_SET%, TMVL(01,%TIME_SET%)
which results in the %TIME_SET%, will have the %PLAN_TIME_SET% member that the user selected when initiating job from the DM pkg in Planning (this all works correctly) as you can see in the log, it's passing the correct time member & getting the prior time member as well that we use to calc periodic values in this YTD CONSOL model
Try to test this:
*START_BADI RUNLOGIC_PH
QUERY = OFF
WRITE = ON
VALIDATION = ON
DEBUG = OFF
LOGIC = PUSHTOPLAN.LGF
APPSET = QEP_BPC
APP = CONSOL
DIMENSION CURRENCY = <ALL>
DIMENSION C_GROUP = <ALL>
DIMENSION FLOW = <ALL>
DIMENSION INTERCO = <ALL>
DIMENSION OPER_NON_OPER = <NONE>
DIMENSION PLAN_WELLNO = <NONE>
DIMENSION RESCAT = <NONE>
DIMENSION VERSION = <NONE>
DIMENSION PLAN_TIME = <NONE>
DIMENSION UOM_CURRENCY = <NONE>
DIMENSION TIME = 2012.11,2012.12
*END_BADI
And later (with DM prompt for PLAN_TIME members - SELECTINPUT(...)):
DIMENSION TIME = %PLAN_TIME_SET%
Post the logs as in prev posts. I have found some interesting behavior.
Vadim
P.S. You can run this script in UJKT to get the log immediately
Hi Vadim - attached is the log from me running it in simulation via t-code UJKT. The ONLY thing I changed in the Badi you provided was I only passed in Time member 2012.12 since the logic called will get the prior time member (2012.11) and it all worked.
Next, as you suggested, for the DM prompt, I changed the DIMENSION TIME = %PLAN_TIME_SET% in the Badi
and initiated the DM pkg in PLANNING model, and it worked successfully. I'm now seeing the data pushed in the PLANNING model.
Thanks you so much for your help, it is greatly appreciated!
Hi Joyce,
It was my original idea that there is something wrong with the TIME scope. But you told me that correct records are generated and even provide some log...
The empty log of the script with badi was also confusing - no errors and significant time to run (10.17 s).
Only after some tests on the real system I understood the effect:
If you have a parameter in the badi call like:
DIMENSION SOMEDIM=<ALL>
and in the calling script you reference the default scope variable like:
*XDIM_MEMBERSET SOMEDIM=%SOMEDIM_SET%
then you will get an empty script log and the script will not run.
If you don't use the default scope variable - the script will run and the log will appear.
I never have this issue with my scripts because I always provided the full scope in the badi parameters.
By the way, it's possible to correct your calling script to support multiple TIME periods with FOR/NEXT or to use CHANGED parameter in the badi call:
CHANGED=TIME
to calculate multiple periods.
B.R. Vadim
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.