如何清除逻辑脚本中的选择数据

2020-09-01 18:10发布

点击此处---> 群内免费提供SAP练习系统(在群公告中)加入QQ群:457200227(SAP S4 HANA技术交流) 群内免费提供SAP练习系统(在群公告中)专家们, 我的问题很基本,所以...

         点击此处--->   EasySAP.com群内免费提供SAP练习系统(在群公告中)

加入QQ群:457200227(SAP S4 HANA技术交流) 群内免费提供SAP练习系统(在群公告中)


专家们,

我的问题很基本,所以请原谅我对脚本的了解。

目前,我们有2个单独的DM包用于YTD计算(称为Logic Sc​​ript),另一个包用于清除数据。

YTD的逻辑脚本:(在Vadim的帮助下)

 * XDIM_MEMBERSET AUDITTRAIL = INPUT_PERIP
 * XDIM_MEMBERSET FLOW = F_NONE
 * XDIM_MEMBERSET CATEGORY = FORECAST_IP
 * XDIM_MEMBERSET RPTCURRENCY = LC
 * XDIM_MEMBERSET INTERCO = I_3RD
 * SELECT(%Y%,[YEAR],TIME,[ID] =%TIME_SET%)
 * SELECT(%M01%,[ID],TIME,[YEAR] =%Y%AND [MONTHNUM] = 1 AND [CALC] = N)
 * SELECT(%M02%,[ID],TIME,[YEAR] =%Y%AND [MONTHNUM] = 2 AND [CALC] = N)
 * SELECT(%M03%,[ID],TIME,[YEAR] =%Y%AND [MONTHNUM] = 3 AND [CALC] = N)
 * SELECT(%M04%,[ID],TIME,[YEAR] =%Y%AND [MONTHNUM] = 4 AND [CALC] = N)
 * SELECT(%M05%,[ID],TIME,[YEAR] =%Y%AND [MONTHNUM] = 5 AND [CALC] = N)
 * SELECT(%M06%,[ID],TIME,[YEAR] =%Y%AND [MONTHNUM] = 6 AND [CALC] = N)
 * SELECT(%M07%,[ID],TIME,[YEAR] =%Y%AND [MONTHNUM] = 7 AND [CALC] = N)
 * SELECT(%M08%,[ID],TIME,[YEAR] =%Y%AND [MONTHNUM] = 8 AND [CALC] = N)
 * SELECT(%M09%,[ID],TIME,[YEAR] =%Y%AND [MONTHNUM] = 9 AND [CALC] = N)
 * SELECT(%M10%,[ID],TIME,[YEAR] =%Y%AND [MONTHNUM] = 10 AND [CALC] = N)
 * SELECT(%M11%,[ID],TIME,[YEAR] =%Y%AND [MONTHNUM] = 11 AND [CALC] = N)
 * SELECT(%M12%,[ID],TIME,[YEAR] =%Y%AND [MONTHNUM] = 12 AND [CALC] = N)
 * XDIM_MEMBERSET TIME =%M01%,%M02%,%M03%,%M04%,%M05%,%M06%,%M07%,%M08%,%M09%,%M10%,%M11%,%M12  %
 *到时
 *是*
 * REC(EXPRESSION =%VALUE%,TIME =%M12%,AUDITTRAIL = INPUT_YTDIP)
 *结束
 * XDIM_MEMBERSET TIME =%M01%,%M02%,%M03%,%M04%,%M05%,%M06%,%M07%,%M08%,%M09%,%M10%,%M11%
 *到时
 *是*
 * REC(EXPRESSION =%VALUE%,TIME =%M11%,AUDITTRAIL = INPUT_YTDIP)
 *结束...
 等等

我们用于YTD的DM程序包只能选择ENTITY和TIME。 (请参阅附件)

现在,我们在此之后立即运行Clear包,在此我们想清除SAME实体和TIME的数据,但要使用AUDIT TRAIL = INPUT_PERIP

我的问题是:

我可以在YTD脚本中包含这些清晰的步骤吗,即 年初至今计算之后; 还是运行清除程序包?

请同时查看高级脚本

YTD软件包

 PROMPT(SELECT ,,,"选择实体并选择第一个预测期的日历年/时期","%ENTITY_DIM%,%TIME_DIM%")
 任务(/CPMB/DEFAULT_FORMULAS_LOGIC,SUSER,%USER%)
 任务(/CPMB/DEFAULT_FORMULAS_LOGIC,SAPPSET,%APPSET%)
 任务(/CPMB/DEFAULT_FORMULAS_LOGIC,SAPP,%APP%)
 任务(/CPMB/DEFAULT_FORMULAS_LOGIC,SELECTION,%SELECTION%)
 任务(/CPMB/DEFAULT_FORMULAS_LOGIC,LOGICFILENAME,YTD_PERIOD.LGF)
 

清除包裹

 PROMPT(SELECT ,,,"选择要清除的实体和时间范围(日历年/每日历年)","%ENTITY_DIM%,%TIME_DIM%")
 INFO(%HARDCODEDDIM1%,| DIMENSION:AUDITTRAIL | INPUT_PERIP)
 INFO(%HARDCODEDDIM2%,| DIMENSION:CATEGORY | FORECAST_IP)
 任务(/CPMB/CLEAR_CUBE,CHECKLCK,1)
 任务(/CPMB/CLEAR_CUBE,SELECTION,%SELECTION %% HARDCODEDDIM1 %% HARDCODEDDIM2%)
 任务(/CPMB/CLEAR_CUBE,DUMPLOADMODE,3)
 任务(/CPMB/CLEAR_CUBE,KEYDATE,%SELECTION_KEYDATE%)
 任务(/CPMB/CLEAR_COMMENTS_FOR_CLEAR,SELECTION,%SELECTION %% HARDCODEDDIM1 %% HARDCODEDDIM2%)
 任务(/CPMB/CLEAR_COMMENTS_FOR_CLEAR,ENABLETASK,0)
 任务(/CPMB/CLEAR_COMMENTS_FOR_CLEAR,CHECKLCK,1)
 

请同时找到两个软件包的附加提示。

谢谢。

ytd-prompt.jpg (28.4 kB)
3条回答
路亽曱_Ryan
2020-09-01 18:17

使用脚本逻辑清除YTD脚本代码之后的数据!

 ...
//现有的YTD脚本

//要清除的范围区域
 * XDIM_MEMBERSET AUDITTRAIL = INPUT_PERIP
 * XDIM_MEMBERSET CATEGORY = FORECAST_IP
 * XDIM_MEMBERSET ...
 ...
//清除范围
 *到时
 *是*
 * REC(EXPRESSION = 0)//清除!
 * END                                                                     

一周热门 更多>