Skip to Content

HowTo create an ABAP process type with a return code (red/green) for use in a process chain in BW 7.x


Various customers have asked me how they could integrate the execution of an ABAP program followed by a return code (red/green) inside a process chain in SAP BW 7.x. This document describes the steps that have to be performed to allow for this functionality.


SAP BW Administrators / Developers.

Table of Contents



Table of Contents

1. Creation of the process type

2. Integration of the process type

1. Creation of the process type

This chapter describes the steps to create the new process type that allows for the integration of an ABAP program with a return code (red/green) inside a process chain.

Step 1: Log on to the BW system.

Step 2: Execute transaction <RSPC>.

Step 3: Open/Display a process chain.

Step 4: Go to the menu <Settings><Maintain Process Types>.

RSPC - Settings - Maintain Process Types.jpg

Step 5: Select the entry where the process type equals <ABAP>.

Step 6: Go to the menu <Edit><Copy As>.

RSPC - Settings - Maintain Process Types - Copy As.jpg

Step 7: Apply the settings as shown in the picture below and press <Enter>.

Process Type ZABAP.jpg

Step 8: Save the new process type.

Process Type ZABAP - save.jpg

2. Integration of the process type

This chapter describes the steps that are required to integrate the new process type in a process chain.

Step 1: Log on to the BW system.

Step 2: Execute transaction <SE38> and enhance the program for which you want to raise a return status Green “MESSAGE i000(zz)” or Red (MESSAGE i000(zz)) as shown in the example below.


Step 3: Open the process chain in which you want to include the new process type.

Step 4: Double-click the <ABAP Program with return Status> process type and fill out the required fields as shown in the picture below.


Step 5: Enter the program name and set the properties for the ABAP program.


Step 6: Add the additional steps for the process chain in case of ‘Green’ or ‘Red’.

ZABAP_RETURNCODE_SAMPLE - process chain view.jpg

You must be Logged on to comment or reply to a post.
  • Hi Edo,

    Thanks for providing very useful information.

    In my project we had  similar situation for taking decision based on some conditions, our requirement was executing different process chain based on conditions.

    We tried ABAP process type with return code but when that process was returning status ‘red’ the process chain was stop and overall status of process chain was ‘red’. Do you have any idea how to overcome with this situation?



    • Hi Rajenda,

      You are right. I experienced the same issue when I tried to determine the current status for a real-time cube (status ‘planning’ or ‘loading’) to make sure that the end-status was the same after backing-up the plan-data. I haven’t found a proper solution yet, but it seems that the document link in the comment from Uladzislau below can help.


      Edo Meinena

      • Hi Edo,

        i have the same requirement. I have created the ABAP Custom Process Type with return code and the process chain with two different flow according to the ABAP Program Status (Red/Green). In the ABAP Program, if some checks fail, we stop the program using the MESSAGE E999(RSPC).

        Executing the chain if the program fails, the subsequent processes are not automatically triggered. If i display the chain in the RSPC monitor, a pop up “Termination Discovered” came up and if i select manually yes , the chain updated the status and triggered the subsequent process properly but it’s not automatic. How can i solve the issue?



        • We had the same issue. Note 2562807 brought us on the right track. Scheduling the job SAP_CCMS_MONI_BATCH_DP helps to notify the system of failed runs and subsequently, the process step is updated.

  • Hi Edo,

    your approach requires creation of customer ABAP process type each time different decision making logic is required. How many different ABAP process type you might need?

    There is much better out of the box approach – using standard Decision process type along with user-defined function. The biggest advantage of this approach is possibility to have multiple alternatives (If … Else If … Else), not just two e.g. true or false. Here is a detailed explanation

    Regards, Uladzislau

    • Hi Uladzislau,

      Thanks for sharing the information. It looks interesting. With regard to your other comment, I would like to point out that your statement about the requirement for a new process type every time decision making logic is needed is not correct. The process type is, just like any other process type, just a placeholder that can read any ABAP-program as a variant. It might have been confusing that I used the same names for both the ABAP-program and the variant. I do realize that more fancy solutions exist to achieve the same result but the document above is designed to describe an easy (and short) way of implementing an ABAP process type with a return code.


      Edo Meinema

  • Hi,

    Good & Helpful Blog.

    I have a concern, I hope without creating generic Process type we can do the same by using ABAP Program process type and include Z program in it.



  • Very useful blog post. Thanks Edo!

    We were formerly just running ABAP programs and manually checking the status every start of the work date. This tweak will prove extremely useful in aligning the load monitorings as part of the automated view in RSPCM.

  • Hi there,

    I have recently become a Dollar Universe user. Few days ago i had to start making some SAP chains at DU. I was wondering which is the difference between a chain containing a number of SAP uprocs and a single uproc with same number of ABAP steps given the fact that those uprocs have the same SAP chain characteristics and only different ABAP Step charasteristics.

  • Hello,

    Thank you for the helpful article. I noticed a small error though. In step two under “2. Integration of the process type” you list “(MESSAGE i000(zz))” as the message for both the Green and Red statuses while “(MESSAGE e000(zz))” is shown in the example screenshot for the Red status which I believe is correct.