cancel
Showing results for 
Search instead for 
Did you mean: 

ABAP program to Cancel messages in Scheduled/Recorded status?

Former Member
0 Kudos

Hi,

Thanks for reading my post...

Can anyone tell me whether there is an ABAP program available (or a variant) that will Cancel messages that are in Scheduled (or Recorded) status?

Messages to be sent from ECC to PI were not sent and are left in Recorded status in ECC. I cannot find the documentation to explain what this status is, but I'm presuming that it's similar to the Scheduled status in PI (though there's not much documentation about that either - for example, what's the difference between the 'green flag' Scheduled and the 'green flag' Released for Processing (WS)? ). {Note to SAP: Could we have a state transition diagram please? Simple, concise and effective.}

Anyway, the 'tick-pencil' button in SXMB_MONI (aka. CTRL-F8) can be used to cancel the messages in Scheduled/Recorded status. But I'm looking for an ABAP program to do this. The documentation seems to 'suggest' that this button might do the same thing as the ABAP program RSXMB_CANCEL_MESSAGES. However, this ABAP program does not cancel messages in Scheduled status (only the messages in Error), whereas the SXMB_MONI CTRL-F8 'tick-pencil' will cancel messages in Scheduled status if they are selected.

Is there another ABAP program available to cancel messages in Scheduled status - or is it possible to create a variant of RSXMB_CANCEL_MESSAGES that will do this? (I'm not an ABAP programmer and I've never created a variant, but looking at the code, it seemed it might be possible to get the program to read messages in Scheduled status rather than Error status.)

Many thanks for any help.

Mark

Accepted Solutions (1)

Accepted Solutions (1)

Former Member
0 Kudos

Hi,

To cancel the meesage with errors in MONI

RSXMB_CANCEL_Message

REgards

Seshagiri

Former Member
0 Kudos

Hi Seshagiri,

Messages are not in Error - please re-read the post. Thanks.

Former Member
0 Kudos

Hi,

Check this

RSXMB_CHECK_MSG_QUEUE

Regards

Seshagiri

Former Member
0 Kudos

Hi Seshagiri,

I think that could be the answer. Also, I found SAP Note 688147.

Will let you know.

Thanks.

Former Member
0 Kudos

Hi Seshagiri,

Yes - that took care of it. Thanks - that's a useful clean-up routine.

Mark

Answers (3)

Answers (3)

Former Member
0 Kudos

Sorry - I got something the wrong way around - it should be 'Scheduled' in ECC and/or 'Recorded' in PI.

prateek
Active Contributor
0 Kudos

I don't think that such a program exists but even if it does, it would not be recommended to use it in the Production environment. Many a times due to high load on PI server or due to slow performance of server, the message gets into the scheduled status and gets processed eventually. If you use such an ABAP report, then it is very much probable that you may end up cancelling some important production message. This is an intermediate step for message processing through integration engine and no job should interfere its processing. It would be better to have a manual process to deal with the issue.

Regards,

Prateek

Former Member
0 Kudos

Hi Prateek,

I understand that caution would be needed, but I do want to cancel these messages.

I've seen a suggestion (in other threads) to delete these messages direct from the database tables - although it's not 'advised'. I need a programmatic way to do this.

kkram
Contributor
0 Kudos

Messages are in scheduled status because they still in the queue in either 'READY' status or 'EXECUTING' status (see SMQ1/SMQ2). You don't want to automatically cancel messages that are in scheduled status because that means you are also going to cancel good messages. However, in some cases, you may want to cancel such messages especially when the message in the queue has been in 'Executing' status for long time (happens in case of long running mapping program or dropped connection etc). Such cases warrant manual intervention and hence the behavior as noted by you.

If you can tell me why exactly you want to cancel messages that are in scheduled status, I can help you more.

Thanks

KK

Former Member
0 Kudos

Hi KK,

The messages are not in the queue.

I do want to cancel these messages.