This topic provides troubleshooting information for the Adapter.
Connection error occurs when you deploy an orchestration using a binding file
Issue: When you deploy the orchestration project using a binding file, BizTalk Server displays the following connection error in Event Viewer:
The adapter failed to transmit message going to send port "sap://Ebizides620:00/800/<username>/en/". It will be retransmitted after the retry interval specified for this Send Port. Details: "Name or password is incorrect. Please re-enter."
This error occurs when the binding file contains a series of asterisks ( * ) in the password field. The password was not assigned correctly to the password field of BizTalk Explorer.
Resolution: Correct the password by manually updating the binding file that is used for deploying on another computer.
To manually update the binding file
-
Navigate to the directory that contains the binding file you exported.
-
Open the binding file, and change the asterisks to the password. For example, you would change the asterisks that are in bold:
<TransportTypeData><CustomProps><AdapterConfig vt="8"><Send
xmlns:xsd="http://www.w3.org/2001/XMLSchema"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-
instance"><batchSize>1</batchSize><systemName>Ebizide
s620</systemName><sapSystemId>00</sapSystemId><userNa
me>rickmit</userName><password>******</password><c
lient>800</client><language>en</language><uri>s
ap://Ebizides620:00/800/v-
shivav/en/</uri></Send></AdapterConfig></CustomProps></TransportTypeData>
Cannot display the GUI page
Issue: Some RFCs and BAPI® programming interfaces provide the ability to open SAP® solution screens and forms. However, Microsoft designed the Adapter to transfer data rather than open SAP screens.
For example, you can use the BAPI_STANDARDMATERIAL_CREATE function to display the SAP Graphical User Interface (GUI) when requested, however when you call this function through the Adapter, the output XML file contains the "Cannot display GUI Page" error message. This behavior is by design.
Non-released segments in SAP are not transmitted
Issue: If you attempt to receive an IDoc for a specific segment release (for example, 620/46C) and trigger the IDoc without specifying the release, the schema will filter all the segments and allow only the control record.
Schema Wizard throws an exception when generating a proxy
Issue: When generating proxy for some RFC or BAPI® programming interface on an SAP® CRM system, the Schema Wizard may throw an exception. This is because some RFCs are intended for internal SAP solution use and therefore will not generate schema.
Conditions under which the Schema Wizard will fail are as follows.
-
There are no input or output parameters
-
There is an inactive table
-
There is an unsupported type
Enabling and Disabling SAP RFC and CPIC Trace
Issue: You want to capture statistics about which remote calls your application or the SAP System are executed. The RFC trace captures the information below.
-
Which function modules have been called remotely by the program to be analyzed
-
Whether the RFC was executed successfully
-
The total time used to process the remote call
-
The type of RFC communication (RFC client or RFC server)
-
The instance the remote call was executed on
-
The technical parameters characterizing the instance
-
The number of bytes sent and received at the RFC
The CPIC trace captures error information including the following information.
-
How the error occurred
-
When the error last occurred
-
Error number and description
One way you can enable and disable tracing is by using a script and setting three environment variables or within the SAP system using transaction SE37. To enable or disable tracing, use the following script.
Set oShell = CreateObject("WScript.Shell")
Set oUserEnv = oShell.Environment("SYSTEM")
'RFC_TRACE
'0 = No trace
'1 = Trace
oUserEnv("RFC_TRACE") = 1
' CPIC_TRACE
' 0 = No trace
'1 = Write error messages in trace file
'2 = Full trace
'3 = Include trace data blocks
oUserEnv("CPIC_TRACE") = 1
oUserEnv("RFC_TRACE_DIR") = "c:\RFCTrace"
The script is configured to do an RFC trace and error message CPIC tracing. Change the values to disable tracing or to include more detail in the CPIC trace.
You can also use SAP transaction SE37 to initiate a trace. One benefit of using the SAP system is automatic formatting which is not available in the connector. For example, leading zeroes can automatically be added to a customer or invoice number.
Note |
|
If an RFC function works in SAP but not in your proxy, it is possible that the SAP system has applied automatic formatting while your proxy has not. |
You can also explore the tracing and monitoring capabilities provided by the SAP system including in the Monitoring area under Tools | Administration.
Intermittent lock failure when trying to send IDOC's to BizTalk Server
With TRFC and QRFC, SAP uses a parameter called a Transaction ID (TID) as a unique identifier within the SAP system and when adding the function module execution request to the SAP system. The TID is similar to a GUID and can be mapped to a GUID or vice-versa using helper functions in the RFC library provided by SAP (librfc32.dll).
The SAP Adapter uses the SQL table SAPTID to temporarily store the TID and relies on three stored procedures to manipulate TID values:
-
mp_sap_check_tid
-
mp_sap_delete_tid
-
mp_sap_insert_tid
This table is used when receiving information from SAP into BizTalk. When the adapter is receiving information, you may encounter the following intermittent error:
RfcAbort - Cannot lock transaction error thrown by SAP server when trying to send IDOC's to BizTalk Server.
Resolution: In SQL Server, grant BTS_HOSTS_USERS role Execute permissions on the stored procedures mp_sap_check_tid, mp_sap_delete_tid, mp_sap_insert_tid in the BizTalkMsgBoxDB database. This will ensure that the role has adequate permissions to execute the stored procedures.
BizTalk service is not receiving IDOC's from the SAP system
If the BizTalk service is not receiving IDOC's, the following activities may help you find the problem.
Examine the list of sent IDOC's
By examining the list of IDOC's that have been sent, you can find out whether the IDOC's you are interested in made it out of the SAP system. Execute the we05 transaction to bring up a search page that you can use to query for IDOC's submitted within a certain time period. The default dates (today's date) are usually sufficient. After executing the query, check the results for your IDOC's; if they are not in the list then they have not been sent.
View the sm58 transaction output
When an attempt to send an IDOC to an external destination fails SAP typically queues the failed IDOC and makes additional periodic attempts to resend. These failed attempts show up in the sm58 transaction. If there are IDOC attempts listed here then the SAP system is attempting and failing to send the IDOC's.
Verify the BizTalk connection
To verify active connections to SAP, run the smgw transaction. When the transaction window is displayed, click the Goto menu and choose Logged on clients. This will bring up a list the services currently registered with the SAP server. You should see your BizTalk connection listed; double-clicking the BizTalk connection will bring up a list of its properties including server name and server IP address.
If your BizTalk server is missing, no IDOC's will be received by your BizTalk application. In the following figure no BizTalk server is connected to the SAP system.
Test the RPC connection
To verify active RPC connections to SAP, run the sm59 transaction to list current RPC ports. When the list is displayed, double-click the port configured for the BizTalk server to view its details. On the details page, click the Test Connection button near the top of the page. This will test the connection between the SAP and the BizTalk systems.
If the connection is successful, the actual mechanism for submitting IDOC's may be failing. One way to test this is to send a different (and less complex) IDOC to BizTalk. You can use the MATMAS (material master) or DEBMAS (customer master) IDOC as these are both structurally simple transactions. Configure the outbound parameters of the selected IDOC to use the BizTalk system and then generate an instance. If the instance succeeds, then the problem is with the IDOC generation mechanism in the SAP system for the original, failing IDOC.