Show TOC

tRFC Between SAP and External SystemsLocate this document in the navigation structure


On external systems, the transactional RFC cannot be fully implemented in the RFC library for the following reasons:

  • A database is not always available in external systems.

  • The RFC library cannot always repeat the RFC call in case of errors, such as network errors.

Therefore, the transactional RFC interface from external systems to an SAP system is implemented as follows:

  • RFC library

    The RFC library provides some special RFC calls for working with tRFC, such as RfcGetTransactionID, RfcInvokeInTransaction, and RfcSetTransactionHandler . It packs and unpacks RFC data between RFC format and tRFC format.

    For an SAP system, there is no difference between requesting these calls from another SAP system or from an external system. For an RFC server program, the RFC function itself (only the RFC function, not the whole RFC server program) can be executed normally, as it is called uisng 'normal' RFC with RfcGetData and RfcSendData.

  • RFC client programs and RFC server programs

    Both programs have to manage the TIDs themselves, to check and executethe requested RFC functions exactly once as the tRFC component in an SAP system does.

  • SAP systems

    In SAP systems, no additional changes are necessary in ABAP programs working with external RFC programs which use the tRFC interface. For ABAP programs, such as RFC client programs, the destination defined in CALL FUNCTION must have 'T' as connection type.


    As of AS ABAP Release 710, you can use the re-designed variant of tRFC and qRFC, now called background RFC (bgRFC) for the RFC communication. The NW RFC SDK also supports bgRFC. However, the NW RFC SDK itself treats a bgRFC call like a tRFC call. Within the SDK there is no visible difference between tRFC/qRFC and bgRFC processing.