Post Data Using Transaction Stringing
A process with multiple templates that uses the synchronous post execution method can use a Return Value, a value returned from the target system, from a template registered to the process when posting subsequent templates in the process. A template with a high priority can use a Return Value from a template with a lower priority in posting. This process is called Transaction Stringing.
Transaction Stringing can use process information from one template (transaction) in a second template (transaction), or it can process two similar transactions within one upload.
For example, transaction stringing can be used to process a template creating a material (MM01) in SAP, then process a second template creating a corresponding information record (ME11). Because the material number is not known at the time the second data source is created, the material number can be passed in from the first data source after the first data source has processed.
NOTE: Only multiple template processes based on a BDC Script, GUI Script or BAPI/RFC template types can use transaction stringing. The process must use the synchronous post execution method. Refer to Create a Process for more information.
NOTE: Transaction Stringing cannot be configured if the process is active.
NOTE: After Post Rules can be added to run after a template in a multi-template process. These rules return data that is used as an input parameter for the next template in the process. Refer to Register After Post Rules to a Process Template for more information.
To configure Transaction Stringing:
-
Create multiple templates based on the data that will be passed from one transaction to another.
NOTE: These templates must be of the type GUI Script, BDC Script or BAPI/RFC. Refer to Record a BDC Script, Record a GUI Script, or Configure a BAPI Template for more information.
-
Activate the templates.
-
Create a process that includes the template that will generate the Return Value used during transaction stringing and uses the Synchronous Post Execution Method. Refer to Create a Process for more information.
-
Add the remaining templates to the process. Refer to Add Templates to a Process for more information.
NOTE: Set the priority order of the templates in the order they should be processed using transaction stringing. Templates are processed in ascending priority order. A template with a low priority is processed before a template with a high priority.
-
Configure the process template loop field mappings to set the return value template and the value to be passed using transaction stringing.
To configure the process template loops and field mappings to use return values on the Process page:
-
Click the Templates icon for a process.
-
Click the Loops icon for the parent template in the process.
NOTE: The INCLUDE check box should not be used for process template loops for a process that posts using the Synchronous Post Execution Method. When posting, the user must post the entire template.
-
Click Edit.
-
Enter PKey in PRIMARY KEY COLUMN NAME.
-
Click Save.
-
Click Field Mappings.
NOTE: The TEMPLATE FIELD UNIQUE NAME and the DESCRIPTION field should have data for all records.
-
Click Edit.
-
Enter either a MAPPINGVALUE or a FIXEDVALUE for every field.
-
Click Save.
-
Navigate to the ProcessTemplate page.
-
Click Loops for the child template that will use the value passed from the parent template.
-
Click Edit.
-
Select the view that will provide the data for the child template’s field mappings in the VIEW NAME list box.
-
Enter PKey in PRIMARYKEYCOLUMNNAME.
-
Click Save.
-
Click Field Mappings.
NOTE: The TEMPLATE FIELD UNIQUE NAME and the DESCRIPTION field should have data for all records.
-
Click Edit.
-
Enter either a MAPPING VALUE or a FIXED VALUE for every field except the field that will use the Return Value. This field should not have data in either MAPPING VALUE or FIXED VALUE.
-
Click Save.
-
Click Vertical View for the field that will use the Return Value.
-
Click Edit.
-
Select the parent template that will pass the return value to the current template in the Return Value Template ID list box.
-
Select an option from the Return Value list box.
NOTE: The Return Value contains the data to pass to the current field. SAP returns up to four return values for each posting and the return values differ for each transaction code. The return values make up the dynamic part of the message that displays to the user in SAP in the status bar after saving the record. For example:
MM01: Message displayed “Material 101 created successfully”.
Return Value 1: 101 = Material Number
FB50: Message displayed “Document 123235 was posted in company code 0001”
Return Value 1: 123235 = Document Number
Return Value 2: 0001 = Company Code
To determine the Return Values to select in the Return Value list box, execute the transaction used by the template manually in SAP and monitor the status bar to determine which return values are passed back via SAP.
-
Click Save once the Return Value template and Return Value are set.
NOTE: On the Horizontal View of the Process Template Loop Field Mappings page, the RV column displays a check mark for the field that will use the Return Value.
-
After the field mappings have been configured, post the process using the StandardSAPPostingBDC Post Method.
-
Set up testing scenarios, if necessary, for a process with multiple templates on the Advanced tab on the Process Post Vertical View to restrict the number of templates that Integrate posts. Enter the priority of the first template to include in the debug process in the Start Template Priority field, and the priority of the last template in the End Template Priority field.
-
Post the data. If the posting fails, troubleshoot the errors using information on the Messages page or download the message file on the Message File page. Refer to Posting Troubleshooting for more information.
-
Resubmit the post after correcting any errors. Click Reset for the process post on the Process Post page’s Vertical View on the Posting tab, then post the data again.
NOTE: After resetting a post it can be submitted again regardless of its status prior to the reset, and regardless of the reason for the failure.
Was this article helpful?
Sorry about that.
Why wasn't this helpful? (check all that apply)
Thanks for your feedback.
Want to tell us more?
Send an email to our authors to leave your feedback.
Great!
Thanks for your feedback.