SAP Function CHANGEDOCUMENT_CLOSE - Change document: Close change document creation

Parameter Reference Type Length Default Optional Text
DATE_OF_CHANGE CDHDR-UDATE D 8 Changed On
NO_CHANGE_POINTERS CDHDR-CHANGE_IND C 1 SPACE X Flag: No documents written
OBJECTCLASS CDHDR-OBJECTCLAS C 15 Object class name
OBJECTID CDHDR-OBJECTID C 90 Object value ID
OBJECT_CHANGE_INDICATOR CDHDR-CHANGE_IND C 1 'U' X Flag: Object inserted, changed or deleted
PLANNED_OR_REAL_CHANGES CDHDR-CHANGE_IND C 1 SPACE X Not used
TCODE CDHDR-TCODE C 20 Transaction in which change was made
TIME_OF_CHANGE CDHDR-UTIME T 6 Changed at
USERNAME CDHDR-USERNAME C 12 Changed by (name)

Parameter Reference Type Length Text
CHANGENUMBER CDHDR-CHANGENR C 10 Change document number

Exception Text
HEADER_INSERT_FAILED SQL error during INSET of header
NO_POSITION_INSERTED No items were entered
OBJECT_INVALID OPEN was called with other object
OPEN_MISSING No OPEN was carried out
POSITION_INSERT_FAILED G/L account number


INCLUDE 'DOCU_HAS_TO_BE_ELABORATED' OBJECT DOKU ID TX
(see also documentation on CHANGEDOCUMENT_OPEN.)
This function module writes the change document header and completesthe processing of the change document creation for an objectcharacteristic.
Beforehand, the change document items must be created with one of thefollowing functions:
CHANGEDOCUMENT_SINGLE_CASE or
CHANGEDOCUMENT_MULTIPLE_CASE or
CHANGEDOCUMENT_TEXT_CASE.
Processing a new object characteristic can only be started if theprevious object characteristic was completed with this module.
All change documents for an object change receive a unique changenumber that is exported by this module.
Example call:
DATA: OBJECTCLASS LIKE CDHDR-OBJECTCLAS,
OBJECTID LIKE CDHDR-OBJECTID,
USERNAME LIKE CDHDR-USERNAME,
DATUM LIKE CDHDR-UDATE,
UZEIT LIKE CDHDR-UTIME,
TCODE LIKE CDHDR-TCODE,
AENDNR LIKE CDHDR-CHANGENR.
CALL FUNCTION 'CHANGEDOCUMENT_OPEN' ...
...
CALL FUNCTION 'CHANGEDOCUMENT_SINGLE_CASE' ...
...
CALL FUNCTION 'CHANGEDOCUMENT_MULTIPLE_CASE' ...
...
CALL FUNCTION 'CHANGEDOCUMENT_TEXT_CASE' ...
...

CALL FUNCTION 'CHANGEDOCUMENT_CLOSE'
EXPORTING OBJECTCLASS = OBJECTCLASS
OBJECTID = OBJECTID
USERNAME = USERNAME
DATE_OF_CHANGE = DATUM
TIME_OF_CHANGE = UZEIT
TCODE = TCODE
IMPORTING CHANGENUMBER = AENDNR
EXCEPTIONS ....
The change documents are stored under a unique number.This number identifies all change documents of anobject value.
Name of the object class for which the change documents were created.The object class must be the same as that specified inCHANGEDOCUMENT_OPEN.
ID or value of the object characteristic. The object characteristicmust be the same as that in CHANGEDOCUMENT_OPEN.

Description
This flag indicates whether the commercial object whose changes arelogged here was inserted, changed ordeleted.
As a commercial object can consist of several lines in a (orseveral) table, it is not possible to identify the actionautomatically.
The action must only then be specified when this information is relevantfor the analysis of the change documents.

Value range
Valid values are:
'I',,the object was inserted.
'U',,the object was changed.
'D',,the object was deleted.

Default
The parameter has the standard value 'U'.

208010Update termination in VERKBELEG_WRITE_DOCUMENT
733978BOMMAT change pointer for every BOM category
593803Term. of update during change of transportation
485845ALE overwritten attributes: Update termination, change docum
407790Characteristics maintenance: Update termination