Read Table

Use the Read Table activity to fetch the data from tables in the SAP system.

Note:

Data can only be retrieved from SAP tables and views. SAP tables configured as clustered/pool tables are not supported.

General Tab

On the General tab, establish connections to the SAP system, and download the schema of the SAP table to be invoked in the SAP system.

The following table lists the configurations on the General tab of the Read Table in SAP activity:

Field Visual Diff Module Property? Description
Name Yes No

Specify the name to be displayed as the label for the activity in the process.

SAP Connection Yes Yes

Click to select an SAP Connection shared resource. The SAP Connection shared resource establishes connections between the plug-in and the SAP system.

If no matching SAP Connection shared resources are found, click Create Shared Resource to create one. For more information, see Creating and Configuring an SAP Connection.

Note: When a process contains multiple Read Table, if you want the activities to use different SAP Connection shared resources, you have to create process properties for the shared resources to be used, and then choose the corresponding process property for the activity. If you choose different SAP Connection shared resources for the Read Table activities in a process by clicking the activities use the same shared resource.

 

Fetch Table Yes  

Click Fetch Table to download the schema of the Table where data is required to be retrieved from the SAP system.

In the Fetch SAP Table dialog, you can download schema for SAP table.

In the Fetch SAP Table dialog, complete the following tasks:

  1. Specify the Table filter to filter out the required tables with the Table Description. The Table filter support the wildcard search.

  2. Click Fetch Table.

  3. Select the table that you want to download, and click OK.

    Note:

    Based on the Table filter specified, only the top 1000 tables from the SAP system appears on the list.

Output Format Yes  

Specifies the output format of the data.

The following formats are supported:

  • XML

  • JSON

  • Avro

Description Tab

On the Description tab, enter a short description for the Read Table activity.

Input Tab

On the Input tab, enter the request for specifying the session ID of the prior activity, maximum number of rows of data returned, and the selection criteria for retrieving data from the SAP table.

The following table lists the input elements on the Input tab of the Read Table activity:

Input Item Data Type Description
sessionID String Enter the session ID of the previous activity.
maxRowsReturned Integer Enter the number of rows that the system fetches.
Request Complex

Specifies the selection criteria for data to be retrieved from the SAP table. The Request type would contain all of the primary key fields that can be used as part of the selection criteria. When mapping values, similar syntax can be used from the ABAP programming language. For example, if SAP table is T001 and the selection criteria requires only entries where primary key BUKRS is either '0001' or '0002' then below value would be mapped. BUKRS EQ '0001' OR BUKRS EQ '0002.'

Note:

When mapping multiple primary key fields, the selection criteria is treated as an AND condition. No other conditions are allowed. Manually specifying the selection criteria sent to the SAP system is not supported.

Since the fields specified in the request are used to select data from a SAP table, it is important that the values be properly padded. In the case of numeric values only for specific data types, the plug-in would pad leading zeros based on the maximum length of the field. To bypass this automatic padding, you can wrap the entire mapped value within a literal function NOPADDING.

Below is an example.

"NOPADDING(BUKRS EQ '0001' OR EQ '0003')"

For the selection criteria, below operators are only supported along with 'OR' or 'AND' to create compound conditions.

- EQ, NE

- LE, LT

- GE, GT

Output Tab

The Output tab shows the session ID of the activity and the data returned from the SAP table based on the selection criteria and output format. It also shows the table name and number of rows returned.

For XML output format, the schema of the data portion is based on the schema of the SAP table or view. For JSON output format, the schema and data is converted into a JSON object and serialized into a string. For Avro output format, the schema is similar too JSON but instead serialized to a binary string.

Fault Tab

On the Fault tab, you can find the error codes and error messages of the Invoke Read Table in SAP activity and the SAP system. The SAP system exceptions are returned by the RFC_READ_TABLE function module in the SAP system.

The following table lists error schema elements on the Fault tab:

Error Schema Element Data Type Description
msgString Displays the error message
msgCodeString Displays the error code