SAP Function /SAPCEM/BAPI_SHIPDOCCEM_CANCEL - Cancellation (Document Status 5) of a CEM Shipping Document

Parameter Reference Type Length Default Optional Text
NUMBER /SAPCEM/BAPI_SDCEM-NUMBER C 10 Document Number of Shipping Document
TESTRUN BAPIFLAG-BAPIFLAG C 1 'X' X Simulation = 'X'

Parameter Reference Length Optional Text
RETURN BAPIRET2 548 Return Parameters

Functionality
The status 'Cancel' is set for a CEM shipping document via this BAPI/SAPCEM/BAPI_SHIPDOCCEM_CANCEL. However you can only cancel ashipping document if various checks are successful. Some of thesechecks are:

  • Authority checks: Is the user authorized to cancel the shipping
  • document ?
    • Document Date: Is the date within the period of current settlement?

    • Status check: Does the document status permit cancelation?

    • PBE-check: Do PBE documents already exist for the equipment in the
    • shipping document?
      • Follow-on document: Do follow-on documents already exist for the
      • shipping document to be cancelled?
        • Availability: In chronological inventory management the equipment/parts
        • in the shipping document must be available after cancellation.

          Notes
          If an error occurs (parameter RETURN contains entries with TYPE E orA), and if this means that the shipping document cannot be cancelled,the caller of the BAPI is responsible for removing all SAP blocks. Thecaller of the BAPI is responsible for the Commit Work.

          Description
          You use the parameter to enter the number of the shipping document tobe cancelled.

          Description
          If you set this indicator updating does not take place.

          Description
          Table of messages
          Messages are collected in this table.
          TYPE Message category: S Success E Error, W Warning, IInformation
          ID Message-ID
          NUMBER Message number
          MESSAGE Message text
          LOG_NO Application log: Log number
          LOG_MSG_NO Application Log: Sequence number of message
          MESSAGE_V1 Message variable
          MESSAGE_V2 Message variable
          MESSAGE_V3 Message variable
          MESSAGE_V4 Message variable
          PARAMETER Parameter name
          ROW Row in parameter
          FIELD Field in parameter
          SYSTEM System (logical system) from which message originates