Skip to main content

Retrieving data from SAP tables using a dynamic schema

This scenario describes a Job that retrieves and joins data of specific records from two tables on an SAP server and displays the data on the console. The tSetDynamicSchema component in the scenario generates a schema from a schema definition file (a csv file); the tSAPTableInput component retrieves data from specific records of the two tables and passes the data to the tLogRow component. In this scenario, the ExtendedConfiguration field of the csv file specifies the two tables; the other fields of the csv file specify the data to retrieved; the condition in the Filter field of the tSAPTableInput component specifies the records to be processed; and the statement in the From statement field joins the retrieved data.

This scenario requires that RFC server is running on your machine and 8.0.1-R2022-04 Talend Studio Monthly update or a later one delivered by Talend is installed on your machine.

The following figure shows the Job.
The following lists the content of the schema definition file (dynaschema.csv in this example).
ExtendedConfiguration;Name;DbName;Type;DbType;Length;Precision;Nullable;Key
{"TableName":"VBRK"};MANDT;MANDT;id_String;STRING;3;0;false;false
{"TableName":"VBRK"};VBELN;VBELN;id_String;STRING;10;0;false;false
{"TableName":"VBRK"};FKART;FKART;id_String;STRING;4;0;false;false
{"TableName":"VBRK"};FKTYP;FKTYP;id_String;STRING;1;0;false;false
{"TableName":"VBRK"};VBTYP;VBTYP;id_String;STRING;1;0;false;false
{"TableName":"VBRK"};WAERK;WAERK;id_String;STRING;5;0;false;false
{"TableName":"VBRP"};POSNR;POSNR;id_Integer;INTEGER;6;0;false;false
{"TableName":"VBRP"};UEPOS;UEPOS;id_Integer;INTEGER;13;0;false;false
{"TableName":"VBRP"};FKIMG;FKIMG;id_BigDecimal;BIG_DECIMAL;3;0;false;false
{"TableName":"VBRP"};VRKME;VRKME;id_String;STRING;5;0;false;false
Information noteNote: For more information about the ExtendedConfiguration property, see tSetDynamicSchema Standard properties.

Did this page help you?

If you find any issues with this page or its content – a typo, a missing step, or a technical error – please let us know!