Bulk Re-Sending Batch Output to Report Repository

本文提供了一种通过PL/SQL脚本批量重新发送在 Peoplesoft Process Monitor 中未成功发布到报告存储库的输出文件的方法。该解决方案适用于大量未发送报告的情况,避免了逐个请求重发的繁琐操作。
If output files from a batch process fail to post to the report repository, you can request that they are resent within Process Monitor. However, if you have had a problem with posting report output for a period of time you could have a large number of processes that have not posted, and it isn't reasonable to request that each of them are resent individually. I have not found anything delivered to repost all unposted content.

If you trace the Process Monitor while resending content for a single process you can see what is updated to force a resend.

PSAPPSRV.20142 (1880)    1-16     11.07.51    0.000039 Cur#2.20142.PMONITOR RC=0 Dur=0.000025 COM Stmt=UPDATE PSPRCSRQST SET DISTSTATUS = :1 WHERE PRCSINSTANCE = :2
PSAPPSRV.20142 (1880)   1-17   11.07.51  0.000009 Cur#2.20142.PMONITOR RC=0 Dur=0.000001 Bind-1 type=2 length=1  value=7
PSAPPSRV.20142 (1880)   1-18   11.07.51  0.000008 Cur#2.20142.PMONITOR RC=0 Dur=0.000001 Bind-2 type=8 length=4 value=458
PSAPPSRV.20142 (1880)   1-19   11.07.51  0.000886 Cur#2.20142.PMONITOR RC=0 Dur=0.000023 COM Stmt=UPDATE PSPRCSQUE SET DISTSTATUS = :1 WHERE PRCSINSTANCE = :2
PSAPPSRV.20142 (1880)   1-20   11.07.51  0.000009 Cur#2.20142.PMONITOR RC=0 Dur=0.000001 Bind-1 type=2 length=1  value=7
PSAPPSRV.20142 (1880)   1-21   11.07.51  0.000008 Cur#2.20142.PMONITOR RC=0 Dur=0.000001 Bind-2 type=8 length=4 value=458
PSAPPSRV.20142 (1880)   1-22   11.07.51  0.000424 Cur#2.20142.PMONITOR RC=0 Dur=0.000027 COM Stmt=UPDATE PS_CDM_LIST SET DISTSTATUS = '8',TRANSFERINSTANCE = 0 WHERE PRCSINSTANCE = :1 AND DISTSTATUS <> '5'
PSAPPSRV.20142 (1880)   1-23   11.07.51  0.000009 Cur#2.20142.PMONITOR RC=0 Dur=0.000001 Bind-1 type=8 length=4 value=458

Hence it is easy to build this simple PL/SQL loop to request to all unsent content is reposted.
BEGIN
FOR x in  (
       SELECT prcsinstance
       FROM   psprcsrqst
       WHERE  diststatus = 4 --that are not posted
       AND    runstatus = 9  --successful processes
       )
LOOP
 UPDATE PSPRCSRQST
 SET    DISTSTATUS = '7'
 WHERE  PRCSINSTANCE = x.prcsinstance;

 UPDATE PSPRCSQUE
 SET    DISTSTATUS = '7'
 WHERE  PRCSINSTANCE = x.prcsinstance;

 UPDATE PS_CDM_LIST
 SET    DISTSTATUS   = '8'
 ,      TRANSFERINSTANCE = 0
 WHERE  PRCSINSTANCE = x.prcsinstance
 AND    DISTSTATUS   <> '5'; --posted
END LOOP;
END;
/
COMMIT
/

As always, the standard rules for updating PeopleTools tables apply. Don't do it unless you are sure you know what you are doing, because it isn't supported, and if it goes wrong you are on your own!
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值