Entering content frame

Object documentation Event inputErrorOccurred Locate the document in its SAP Library structure

ALE will trigger the event inputErrorOccurred when the inbound function module's import parameter MASS_PROCESSING is set to "'X". In this case ALE is treating the inbound IDoc(s) as a packet, even if it only contains one IDoc.

Since some IDocs in a packet could be processed successfully while others fail, the export parameter WORKFLOW_RESULT cannot be used to set the container parameter RESULT. Instead, the parameter takes on different values according to the parameters used in the table Return_Variables:

 

How to Set the Parameter RESULT when MASS_PROCESSING = "X". Note that for a given IDoc number (in field Doc_Number), you should only use one of the above three names. The names are case sensitive.

Wf_param

Value of RESULT in event container

Error_IDOCs

99999

Retry_IDOCs

1

Continue_IDOCs

2

 

You could use these three values as follows: inputErrorOccurred could be used to trigger a Workflow, which branches according to the value of the parameter RESULT:

 

Possible Values of RESULT in a Workflow

RESULTValue

Action defined in Workflow

1

Retry the IDoc n minutes later, using a new task using the method InputBackground. This could be used to retry IDocs that failed because an application was temporarily locked by another user or process.

2

Process the IDoc in some other manner.

99999

Error handling, using the standard/customer task

 

Export parameter values when processing packets of IDocs, when IDoc 4711 was successfully processed, creating application object no 1234; IDoc 4712 caused an error for which the event's parameter RESULT = 99999; IDoc 4713 caused an error for which RESULT = 2; IDoc 4714 caused an error for which RESULT = 1.

Parameter

Value

In_Update_Task

" " (i.e. initial value) - Update task not used

Call_Transaction_Done

" " (e.g. initial value)

Workflow_Result

"99999"

Application_Variable

" " (e.g. initial value)

Idoc_Status

The table must contain four records with fields containing:

 

Docnum

Status

 

4711

53

 

4712

51

 

4713

51

 

4714

51

 

The Msgid etc. fields of the status record for IDocs 4712, 4713 and 4714 must contain the error message.

Return_Variables

The table must contain the following five entries:

 

Wf_param

Doc_Number

 

Processed_IDOCs

4711

 

Appl_Objects

1234

 

Error_IDOCs

4712

 

Continue_IDOCs

4713

 

Retry_IDOCs

4714

 

If processing the inbound IDoc does not create or change an application object, the "Appl_Objects" entry can be omitted - it makes no sense without a document number.

Serialization_Info

Empty if not using serialization

 

 

 

Leaving content frame