Handling ABAP Programs

Imported ABAP programs can easily be selected in the Submit Wizard, only a character sequence of the name needs to be entered; this avoids typos.

ABAP programs can have Variants, which can be removed and/or edited once they are imported. You can also use temporary variants, which will be deleted in the SAP System once the job has finished in the SAP System.

Imported ABAP programs can be scheduled with the following Process Definitions:

These Process Definitions can be duplicated and tailored to your needs. When you specify a default Queue, all SAP systems that are linked to the Queue will be displayed first in the SAP Systems parameter. If you choose an SAP system that is not linked to the default Queue, you will have to specify the correct Queue.

Retrieving Spool Output to Process Servers

You specify a Process Server on the SAP system to retrieve output to. The Process Server must be a Platform Agent and the underlying platform must support JCo 3.1 or higher.

Additional Print Parameters

The additional print parameters can be generated when importing CCMS jobs by setting the parameter Generate Extra Print Parameters? ( EXTENDED_PRINT_PARAMETERS ) to Yes.

It is also possible to duplicate any of the AbapRun Process Definition and add the parameters there. The following parameters are recognized:

  • EMAIL_ADDRESS - The email address for the mail printer
  • PAGE_FROM / PAGE_TO - page range, numeric values
  • DRAFT_MODE - draft mode. Valid values: Y (Yes) and N (No)
  • PAGE_ORIENTATION - page orientation. Valid values: L (Landscape) and P (Portrait)

Note: Due to the limited size of the field in SAP, the max length of the email address is limited to 50 characters.

Note: According to SAP Note 513352, printing with access method "M" (email printer) will not be developed further.

Retrieving Part of the Job Log

You can retrieve part of the job log by duplicating one of the AbapRun Process Definitions and specifying one of the following parameters:

  • JOBLOG_FIRST_LINES - retrieve the first <n> lines of the job log
  • JOBLOG_LAST_LINES - retrieve the last <n> lines of the job log

When filled with a value > 0, only the given number of lines either from the beginning or from the end of the joblog is retrieved.

Temporary Variants

By duplicating the AbapRun Process Definitions and adding parameters, you can make use of temporary variants. A temporary variant is created for the job and deleted once the job has finished.

You specify the values and select options by creating parameters with names matching the technical name of the parameter or select option and setting Create Temporary Variant? or TEMPORARY_VARIANT to Y. You can use the SAP Object Editor to inspect previously imported variants for the specific names, see Creating and Modifying Variants in Redwood Server for more information. These parameter names must be all upper case.

Variant Parameter Syntax

Variant parameters should be string parameters, with PAR_ or SEL_ prefixes, for parameter and select options, respectively. Their names must contain the name of the parameter/select option in SAP. Select options can either have a single value such as entry or single value, multiple values, ranges, and/or exclusions enclosed in square brackets[], such as [a,c-m,!d,!f,!g].

The following operators are available for select options, the mathematical syntax can only be used in RedwoodScript and is displayed here for clarity:

Syntax Meaning Mathematical Syntax
NOT Not !
EQ Equals =
NE Not Equals !=
NE Not Equals <>
GE Greater than or equals >=
GT Greater than >
LE Less than or equals <=
LT Less than <

Note: When you specify date-ranges, make sure you put spaces between the dates and the hyphen (-), the range 21.02.2020 - 31.12.2020 is valid and this one is not valid:21.02.2020-31.12.2020.

Tip: If you want to specify two or more exact values, you can create a parameter for each select option.

Example

You have a Process Definition with the following parameters:

  • PAR_NOEX - Without Extract, set to X
  • SEL_FLDATE - Flight Date, set to BT and 21.02.2010 - 31.12.2010

Another example of a Process Definition with parameters:

  • PAR_NOEX - Without Extract, set to X
  • SEL_CAR - Airline, set to BT and [AA-ZZ, !BC, !AF]

Alternate example of Process Definition with parameters:

  • PAR_NOEX - Without Extract, set to X
  • SEL_FLDATE_01 - Flight Date, set to GE and 01.02.2010
  • SEL_FLDATE_02 - Flight Date, set to LE and 18.02.2010

Note the use of two FLDATE select options with two exact values.

Waiting for Child Jobs

By duplicating the AbapRun Process Definitions and adding the following parameter, you can make the job not wait for child jobs:

Parameter Description Direction Data Type Values
WAIT_FOR_CHILD_JOBS Wait for child jobs? In String N No, I Ignore (jobs not shown in Redwood Server), Y Yes (default)

Waiting on an SAP Event

By duplicating the AbapRun Process Definitions and adding the following two parameters, you can make the job wait for an event in SAP:

Parameter Description Direction Data Type
STARTCOND_EVENTID batch event ID In String
STARTCOND_EVENTPARM parameter of the event ID In String

Note that you have to duplicate the Process Definition and modify the duplicate.

Showing Log/Spool of Children

By duplicating the AbapRun Process Definitions and adding the following parameters, you can show the spool or the log of child jobs in SAP:

Parameter Description Direction Data Type
CHILD_SHOWLOG Show log of child jobs? In String
CHILD_SHOWSPOOL Show spool of child jobs? In String

Note that you have to duplicate the Process Definition and modify the duplicate.

Ignore Application Return Code

The return code can be ignored on four levels:

  • Process Server-level - set the Process Server parameter SAP_IgnoreApplicationReturnCode to true
  • Process Definition-level - create a parameter named IGNORE_APPL_RC
  • registry entry /configuration/sap/<Partition>.<SAPSystem>/xbp/IgnoreApplicationReturnCode, only valid for the specified SAP system
  • registry entry /configuration/sap/xbp/IgnoreApplicationReturnCode, valid for all SAPR3 processes across all SAP systems

The settings are processed in this order, the first setting found has precedence:

  1. Parameter IGNORE_APPL_RC, only valid for all processes of this Process Definition.
  2. Process Server parameter SAP_IgnoreApplicationReturnCode, only valid for all processes that run on the Process Server.
  3. Registry entry /configuration/sap/<Partition>.<SAPSystem>/xbp/IgnoreApplicationReturnCode, only valid for the specified SAP system.
  4. Registry entry /configuration/sap/xbp/IgnoreApplicationReturnCode, valid for all SAPR3 processes across all SAP systems.

SAP_AbapRun

This Process Definition is used to run ABAP's via the XBP interface in SAP Systems. This Process Definition works with every version of the XBP interface, yet it offers a limited set of print and archive parameters (only those that are available in XBP 1.0) if you do not load the Redwood Transport files.

Note: If you need to use the optional Archive text information field parameter, known as Text in SAPGUI, you will have to use the Process Definition SAP_AbapRunPrint or SAP_AbapRunPrintExt.

SAP_AbapRunPrint

This Process Definition is used to run ABAP's via the XBP interface in SAP Systems. This Process Definition makes use of the extended capabilities of the XBP 2.0 interface, which provides an extended the set of print and archive parameters. This Process Definition works on every version of the XBP interface, yet on versions below 2.0 most of the print and archive parameters will be skipped.

SAP_AbapRunPrintExt

This Process Definition is used to run ABAP's via the XBP interface in SAP Systems. This Process Definition makes use of the extended capabilities of the XBP 3.0 interface to set the spool list recipient and retrieve application log and batch statistics of the SAP job. This Process Definition works on every version of the XBP interface, yet on versions below 3.0 the new functionality is disabled.

If you set Print/Archive mode to Archive only or Print and Archive, the following additional Archive parameters must be set:

  • Archive SAP object - Referred to as Obj.type in SAPGUI
  • Archive object - Referred to as Doc.type in SAPGUI
  • Archive info - Referred to as Information in SAPGUI
  • Archive text information field - Referred to as Text in SAPGUI

SAP_ClosingCockpit_AbapRun

This Process Definition is based on the SAP_AbapRunPrintExt Process Definition and contains additional parameters for Closing Cockpit. This Process Definition requires closing cockpit integration to be configured.

SAP_SolutionManager_AbapRun

This Process Definition is based on the SAP_AbapRunPrintExt Process Definition and contains additional parameters for Solution Manager. This Process Definition requires Solution Manager Integration to be configured.

See Also