Adapter for SAP 10.1 | webMethods Adapter for SAP Documentation | webMethods Adapter for SAP Installation and User’s Guide Documentation | Routing Messages Through Adapter for SAP | Sending an RFC from an SAP System to Adapter for SAP | The SBCHEADER Table
 
The SBCHEADER Table
 
Example of Using an SBCHEADER Table
You can write an ABAP wrapper that calls a function module with an RFC destination and add an additional table to the call statement.
Note:
This table must not be defined in the function interface.
The name of the table must be SBCHEADER and it must have the following structure.
Component
Component type
DTyp
Length
Dec. places
Short text
NAME
SBCNAME
CHAR
32
0
SBC routing table, Keyfield
VALUE
SBCVALUE
CHAR
255
0
SBC routing table, value of Keyfield
This structure is defined in the SAP system starting with release 4.6A under the name SBCCALLENV. If you do not have this structure in your system, define a similar one as above.
The header table can contain an arbitrary number of key/value pairs. If you want to pass additional keys to Adapter for SAP, you can define your own name/value pairs and insert them into the SBCHEADER table.
You would read out these fields inside a java module in Adapter for SAP with the following statements (case-sensitive):
IDataCursor idc = pipeline.getCursor();
IData sbcHeader = IDataUtil.getIData( idc, "sbcHeader");
if (sbcHeader != null)
{
IDataCursor headerCursor = sbcHeader.getCursor();
String property = IDataUtil.getString( headerCursor, "myProperty");
headerCursor.destroy();
System.out.println("Property was "+property);
}
idc.destroy();
If you want Adapter for SAP to invoke a routing notification to route the RFC, the header table must contain the sender and receiver for the RFC. When determining the routing notification to invoke, the routing listener uses the sender and receiver you specify in the header table and matches message types against the RFC name in place of a message type.
To have Adapter for SAP use a routing notification, include the following information in the header table:
Keys
Value
sender
Name of the sender. This name should match the name of a sender in the routing notification you want the routing listener to use to route the RFC.
receiver
Name of the receiving partner. This name should match the name of the receiver in the routing notification you want the routing listener to use to route the RFC.
If you want to control the routing of an RFC from the SAP system directly (without requiring a routing notification on Adapter for SAP), you can include transport information in the header table. The transport indicates where Adapter for SAP is to route the incoming RFC. When Adapter for SAP receives an RFC that specifies the transport, it does not invoke a routing notification but directly passes the RFC to the specified transport. The transports that you can identify in a header table to dynamically route an RFC through Adapter for SAP are:
*Route the RFC to an Integration Server service
*Route the RFC to an SAP system
*Post the RFC-XML to a URL
The following describes the key/value pairs you must specify for each transport you can specify.
*To route the RFC to an Integration Server service, use Integration Server service transport.
Key
Value
transport
IS
This value identifies the transport. Specify the value exactly as specified above.
serverAlias
Name of the Integration Server on which the service to invoke resides. If the service resides on the server that routes the message, specify (local). Otherwise, specify an alias for a remote server. For the routing to be successful, the server routing the RFC must have the defined alias for the remote server.
folderName
Name of the folder in which the service resides. The folder name is case sensitive; use the exact combination of upper and lower case letters.
serviceName
Name of the service to which to pass the RFC. The service name is case sensitive; use the exact combination of upper and lower case letters.
valueScope
Where you want Adapter for SAP to store the connection to the remote server.
To save the connection in your own session, specify SESSION. Use SESSION when the work being performed requires state be maintained.
To save the connection in a shared area, specify GLOBAL. Use GLOBAL when the work being performed is stateless.
*To route the RFC to an SAP system, use the RFC transport.
Key
Value
transport
RFC
This value identifies the transport. Specify the value exactly as specified above.
serverName
RFC Connection alias to which you want the RFC routed.
*To post the RFC-XML to a URL, use the XML transport.
Key
Value
transport
XML
This value identifies the transport. Specify the value exactly as specified above.
url
URL to which you want to post the RFC.
xmlType
The XML format you want the routing listener to use for the RFC. Specify SAP-XML if you want the RFC in an XML format that is compliant with the SAP XML specification. Specify Values-XML if you want the RFC in webMethods native XML format.
httpUser
User name to supply for a user name/password authentication challenge (optionally).
httpPassword
Password to supply for a user name/password authentication challenge (optionally).
For sending RFCs as bXML, please refer to RFC Based XML Messages Using IFR Format.