IBM Support

Configuring a logical system in SAP for use with the IDoc Extract and Delta Extract

Question & Answer


Question

How do I configure a logical system in SAP for use with the IDoc Extract and Delta Extract?

Answer

A logical system is a unique ID within an SAP system that identifies a partner communication system. This partner system can be another SAP system, or it can be an external system such as the IDoc listener component of the Pack for SAP Applications. SAP uses this identifier as part of a model defining the way it distributes data through its ALE interface.

Important: Each logical system in your environment must map to a unique program ID in order to avoid ambiguity. Also, a given logical system should only be used on a single Datastage server. To ensure this, it is advisable the logical system name be defined using DataStage server name so the chances of using the same logical system in another DataStage server are minimized.

Example configuration:
Datastage host: mlcsvm211
SAP host: ipsvm00770
Logical system and RFC Destination: both named mlcsvm211
Program ID and Distribution Model View: both named mlcsvm211.ipsvm00770

In SAP terminology inbound means from external system towards the SAP system, while outbound means from the SAP system to the external system.

The message types required are as follows:
A. For both IDOC Extract and Delta Extract:

-for inbound parameter, configure the message type STATUS.
Note: For Delta Extract stage, if the message type STATUS is not configured, Delta Extract Stage jobs may abort with timeout error message Data completion flag is not raised during stage run time when run with the option Acknowledge IDoc reception to the SAP system enabled in IDoc listener settings in Datastage Administrator for SAP.
B. For Delta Extract:
-for outbound parameter, configure the message type RSINFO. In Outbound Options indicate the Basic IDoc Type RSINFO. Under Output Mode select Transfer IDoc Immediately.
-for inbound parameter, configure the message type RSRQST. In Inbound Options indicate the Process code RSRQ.
(see below for an example with screenshots)


Creating a new Logical System

Defining Logical System Names

To avoid any confusion, participating systems (logical systems) in a distributed environment must have an unique ID (name). This name is assigned explicitly to one client in an SAP system. When you have set up two clients for the exercise, you must notify them which logical systems exist in the distribution environment and what the description of their own client is. When a transaction is executed which sends an IDoc from a source logical system to a destination logical system (for example, sending and receiving partner), the transaction is implemented by sending the IDocs from one client to the other. Generally, both the source and destination ends of the transaction must be configured, but in our environment the source logical system and client are already configured for us. We are only interested in configuring a destination to send IDocs to.

The first step is to define the logical system:

  1. Execute transaction SALE. From here, choose IDOC Interface/Application Link Enabling (ALE)>Basic Settings>Logical Systems>Define Logical System.
  2. Click the New entries button
  3. Enter a name and short description for your logical system
  4. Click the Save button. An Enter change request dialog is displayed. Click to dismiss.


Assign Client to Logical System

Next, map the logical system name that you created in the first step to a client:

  1. Execute transaction SALE. Choose IDOC Interface/Application Link Enabling (ALE)>Basic Settings>Logical Systems>Assign Client to Logical System
  2. Click the New entries button
  3. Enter a client number not already defined in the system.
  4. Enter a city, the logical system name created in Defining Logical System Names, a currency code from the list (USD = US dollars), and choose a client role from the list. The most important selection is the Logical System.
  5. Click the Save button. Dismiss the information dialog that comes up afterwards.


Defining the Communication Parameters

For the two logical systems to be able to communicate with one another, they must know how to connect to each other. The RFC destination provides this information. In the case of our IDoc Extract Pack, since DataStage is an external system, we use a Transactional RFC connection via TCP/IP to receive IDocs from the sending SAP system and to send a status update back that indicates that we have received the IDoc. In order for this connection to happen, we must create the RFC destination:

  1. Execute transaction SALE. Choose IDOC Interface/Application Link Enabling (ALE)>Communication>Create RFC Connections. Alternatively execute transaction SM59 directly.
  2. Click Create
  3. Type a name in for your RFC destination. IMPORTANT: It is much easier to configure in later steps if the RFC destination name is the same as that of the logical system defined in Define Logical Systems.
  4. Select a Connection Type T, and add a description
  5. Click the Save button. The screen will change somewhat at this point, presenting an Activation Type label.
  6. Click the Registration button under Activation Type
  7. Enter a Program ID the box provided under Registration. This is an identifier that will be used as the program ID our RFC server will register itself as with this SAP instance, and is the only communication component required for DataStage.
  8. For Delta Extract Stage, it is mandatory to select Unicode as Communication Type with Target System in Unicode tab.


Modeling the Distribution

The systems involved in the distribution must know which messages are to be distributed. They must know where the messages are coming from and where they are going to. This information is specified in the distribution model. IDoc distribution is based on the distribution model and is directly controlled by it.

The following sections show you how to model a message flow between your two logical systems. You are going to distribute material master data from one logical system to another. Modeling involves maintaining model views of the distribution model. To create a new distribution model view, follow these steps:

  1. Execute transaction SALE. Choose IDOC Interface/Application Link Enabling (ALE)>Modelling and Implementing Business Processes>Maintain Distribution Model and Distribute Views
  2. Click the Change button
  3. To create a new distribution model, click the Create model view button. Type in a short text description and a technical name. To use an existing model, simply select one of the existing entries.
  4. To define the messages that can be sent in this distribution model, click on the Add message type button. See the message types required above.
  5. The logical system associated with the SAP client is T90CLNT090 or similar. The logical system associated with Datastage was previously defined above in Defining Logical System Names. The model view is the model view of your choice, and the message type corresponds to the type of message you want to be sent to your client.
  6. Click the Save button.

Generate Partner Profiles

When you have created the distribution model, you must select the model view in Partner Profiles to tell the participating systems how ALE is to execute the transfer the data.

  1. Execute transaction SALE. From here, choose IDOC Interface/Application Link Enabling (ALE)>Modelling and Implementing Business Processes>Partner Profiles>Generate Partner Profiles
  2. Select the Model View created or modified under Modeling the Distribution.
  3. Execute the transaction. This will only work correctly at this point if you heeded the advice in Defining the Communication Parameters to give your RFC destination the same name as your logical system.

Adding a message type to an existing logical system

Occasionally, the capabilities of a given logical system to receive IDocs must be expanded to include new message types. In order to do this expansion, repeat the steps under section Modeling the Distribution, while skipping step 3.
 

Modifying the tRFC options for an existing logical system
        
The SAP Server schedules a report which executes failed packets every 15 mins by default. tRFC options for a Logical Systems can be modified to change the retry duration for scheduling this report. The options are specific to each destination associated with the logical system.
1. Go to t-code SM59.
2. Expand TCP/IP connections -> double-click the applicable TCP/IP connection -> choose the destination associated with the logical system -> Open it in change mode.
3. From the Destination menu, go to Edit and click tRFC Options.
4. Set Time betw. 2 tries [mins] to the desired value (eg. 1) and click on continue.
5. From the Destination menu, choose Save.

Example configuration
Datastage host: mlcsvm211
SAP host: ipsvm00770
Logical system and RFC Destination: both named mlcsvm211
Program ID and Distribution Model View: both named mlcsvm211.ipsvm00770
Datastage connection:
image

Distribution Model View in SAP:
image

RFC Connection in sm59:
image

[{"Business Unit":{"code":"BU059","label":"IBM Software w\/o TPS"},"Product":{"code":"SSZJPZ","label":"IBM InfoSphere Information Server"},"ARM Category":[{"code":"a8m50000000L1HjAAK","label":"DataStage->Enterprise Packs->SAP Applications"}],"ARM Case Number":"","Platform":[{"code":"PF002","label":"AIX"},{"code":"PF016","label":"Linux"},{"code":"PF033","label":"Windows"}],"Version":"All Version(s)","Line of Business":{"code":"LOB10","label":"Data and AI"}}]

Document Information

Modified date:
05 May 2020

UID

swg21449730