Show TOC Start of Content Area

Background documentation Error Handling in the Update Routine  Locate the document in its SAP Library structure

In an update routine, you have the option of transferring error messages and warnings to the monitor.

Note the following:

·        When you use the update routine to transfer messages to the monitor, you need to maintain in the scheduler the settings that control how the system behaves if an error occurs. See also Treating Data Records with Errors.

·        If you set the RETURNCODE = 0 in your routine, the record is posted. If you transfer X-messages, A-messages, or E-messages to the monitor, the record is written to the error request at the same time, because the monitor table contains error messages. With warnings (W-messages) no entry is made in the error request.

·        Controlling error behavior with ABORT:

If ABORT <> 0 the loading process is terminated.

·        If, you set the RETURNCODE <> 0 in your routine, there are two possible outcomes, depending on whether you are dealing with a characteristic (key field in an InfoCube) or a key figure (a data field):

¡        With key fields, the data record is skipped and the next data record along is processed instead.

¡        With key figures, the processing of the key figures is terminated, and the content of the corresponding key figure is initialized and transferred to the target table.

Caution

This process presents no problems so long as you update in an additive way, since this simply involves adding a 0. If, however, you use the minimum and overwrite update methods, this process becomes problematic. In these cases, you do not use a RETURNCODE, because if you do, any existing entries will be initialized, meaning that they will be overwritten with an empty or blank value.

 

End of Content Area