Using a Single Connection to Connect to Two SAP Systems

You can use a single connection to connect to two different SAP systems.

Assume a scenario that you are working on two SAP systems, one SAP system is named CER and the other SAP system is named LCM. Both SAP systems are assigned RFC destinations as RFCTEST and program ID as RFCTEST.

Assume you configured an outbound service running on the CER SAP system. Refer to the following procedure to configure the LCM SAP system to let it use the same SAP adapter configuration.

Procedure

  1. Log in to the second SAP system, LCM, run transaction sm59.
  2. On the Configuration of RFC Connections page, select RFC Connections > TCP/IP connections > RFCTEST.
  3. On the RFC Destination RFCTEST page, click the Technical settings tab.
  4. Click Display <-> Change (Ctrl + F1).
  5. Enter the same values for the Gateway host and Gateway service field as the CER SAP system.
    Note: When assigning a specific gateway host to an RFC destination, ensure that this gateway host is available at all times. Regardless of whether or not you are able to make an RFC request from another host, if the specified gateway host is unavailable, the RFC request to the adapter cannot be successful.
  6. Click Save.
  7. Click Connection Test to test the connection.
  8. Save the destination.

Result

Now you are ready to run the adapter configuration from the second SAP system which is the LCM in this scenario.

However, the disadvantage in this scenario is that if the CER SAP system goes down, the adapter configuration cannot obtain messages from the LCM SAP system. In a scenario where one adapter services can connect to multiple program IDs of multiple SAP systems the problem does not arise.