IDoc Parser

Use the IDoc Parser activity when the XML output is required from the IDoc messages received by the IDoc Listener activity.

Different IDoc types require different IDoc Parser activities to perform the parse process.

Note:
  • The IDoc Parser activity requires the TIBCO Enterprise Message Service.
  • The IDoc Parser activity does not support the job tuning property, FlowLimit.

See Job Tuning for details.

General Tab

On the General tab, establish connections to the SAP system and the messaging source separately, and download the schema of the IDoc to be parsed by the IDoc Parser activity.

The following table lists the configurations on the General tab of the IDoc Parser activity:

Field Module Property? Description
Name No Specify the name to be displayed as the label for the activity in the process.
SAP Connection Yes Click to select an SAP Connection shared resource. The SAP Connection shared resource establishes an inbound connection between the plug-in and the SAP system. The inbound connection is only used to download the IDoc schema at design time.

If no matching SAP Connection shared resources are found, right-click the Resources folder, and then click New > SAP Connection to create a new connection. See Creating and Configuring an SAP Connection for details.

IDoc Name No Click Fetch IDoc to download the schema of the IDoc to be parsed.
In the Search IDoc dialog box, complete the following tasks:
  1. Specify the IDoc filter to filter out the required IDoc types with the basic IDoc type name.

    The IDoc filter supports the wildcard search. The default value of the IDoc Filter field is .*, and the value of this filed is case sensitive.

  2. Select an IDoc type.
    • Basic Type: select Basic Type if you want to download the IDoc schema of the basic type. Only the basic IDoc types matching the IDoc filter can be filtered out.
    • Extended Type: select Extended Type if you want to download the IDoc schema of the extended type. The extended IDoc type name includes the name of the basic IDoc type that it is extended from. Therefore, the extended IDoc types can be filtered out by using the corresponding basic IDoc type name.
  3. Click Fetch IDoc.
  4. Select the IDoc type that you want to download and click OK.

    Ensure that the selected IDoc type and the associated segments have been released in the SAP system.

    You need to clear the Download IDoc specific to SAP release checkbox to filter those IDocs that have been released, but do not have a release number assigned.

When the IDoc schema is downloaded, an XSD file is created. The XSD file cannot be visible in the project, but it can be picked from the activity if required.

Note:
  • When an IDoc schema is downloaded to the plug-in, if new segment definitions are added to the IDoc schema because of the upgrade of the SAP system, you have to refresh the IDoc schema in the plug-in.
  • You must specify the correct version for the Seg. release in IDoc type field in the outbound partner profile so that the version of the segment definition in the downloaded IDoc schema matches the version of the IDoc type from the SAP system.
  • When the IDoc Parser activity is in the same process as the JMS Send Message activity, if you refresh the IDoc schema, it might cause TIBCO Business Studio to be unresponsive. If the IDoc schema has to be refreshed, temporarily remove the reference of the IDoc schema in the JMS Send Message activity before refreshing the IDoc schema.
  • If the IDoc schema requires to be refreshed from the SAP system, then ensure that the Download IDoc specific to SAP release check box is configured accordingly. The Download IDoc specific to SAP check box is by default always selected whenever the user clicks the Fetch IDoc button.
Messaging Source No The messaging source where the activity retrieves the IDocs to be parsed.

Only the JMS type is supported.

JMS Connection Yes Click to select a JMS Connection shared resource. The JMS Connection shared resource establishes a connection between the plug-in and the EMS server where the activity retrieves the IDocs to be parsed.

If no matching JMS Connection shared resources are found, click Create Shared Resource to create one. For more details, see the TIBCO ActiveMatrix BusinessWorks documentation.

Max Session Yes Specify the number of IDoc messages to be processed concurrently.

The default value is 1.

If you set the value of this field to negative numbers or zero, the value of 1 is used automatically at run time.

See Job Tuning for details.

Description Tab

On the Description tab, enter a short description for the IDoc Parser activity.

Advanced Tab

On the Advanced tab, specify the destination used to retrieve the IDocs to be parsed, and the message selector.

The following table lists the configurations on the Advanced tab of the IDoc Parser activity:

Field Module Property? Description
Sequence Key No This field contains an XPath expression that specifies the order in which the process runs. Process instances with sequencing keys that have the same value are executed sequentially in the order in which the process instances were created.
Custom Job Id No This field contains an XPath expression that specifies a custom job ID for the process instance. This ID is displayed in the $_processContext process variable. The custom job ID for the process instance.
Receive IDoc Destination Yes This field is used to retrieve the IDoc to be parsed.
Note: This destination must be the one that the IDoc Listener activity uses to persist IDocs.
Acknowledge Mode No This field is used to control the acknowledgment of the message from the Receive IDoc Destination Queue. The possible values are:
  • Auto for automatic acknowledgment.
  • Client for Client acknowledgment.

The default value is automatic acknowledgment

Note: When using Client Acknowledgment, you must confirm the message using the Confirm activity from the General Activities palette. In terms of error handling, to capture the exception generated by the activity during processing the message, the CatchAll should be used.
Message Selector No The message selector is used to select a specific IDoc message from the receive IDoc destination.

The default value is SAPIDOC_IDOCTYP = 'IDoc_Type' AND SAPIDOC_CIMTYP = 'Cim_Type' .

You can also use other JMS properties, for example, SAPIDOC_OUTMOD, SAPIDOC_STATUS, and SAPIDOC_CREDAT.

If a syntax error occurs, you can click Reset Syntax next to the Message Selector field to reset this field.

Output Tab

The Output tab of the IDoc Parser activity shows the parsed IDoc in the XML format.

The output of the IDoc Parser activity follows the following rules:
  • Any space characters at the beginning of the output item value are preserved.
  • Any space characters at the end of the output item value are removed.
  • When space characters at the end of the output item value are removed, if the output item has no value left, the corresponding output item is not displayed in the activity output.

Fault Tab

On the Fault tab, you can find the error codes and error messages of the IDoc Parser activity. See Error Codes for more detailed explanation of errors.

The following table lists error schema elements on the Fault tab of the IDoc Parser activity:
Error Schema Element Data Type Description
msg String Displays the error message.
msgCode String Displays the error code.
IDocNumber String Displays the number of the received IDoc.