Application Development Discussions
Join the discussions or start your own on all things application development, including tools and APIs, programming models, and keeping your skills sharp.
cancel
Showing results for 
Search instead for 
Did you mean: 

Change Document Object via SCDO

Former Member
0 Kudos

Hi,

I have created one Change Document Object ZCHNGDOC via TCode SCDO to track the changes in Z Table ZTAB1 .

The Change Document Object ZCHNGDOC has generated one Include Program FZCHNGDOCCDT which again consists of two Includes. It also generated one Function Module ZCHNGDOC_WRITE_DOCUMENT .

While changing the records in Z Table ZTAB1 , no changes has been tracked in the standard table CDHDR and CDPOS for this Change Document Object ZCHNGDOC .

Whether I have to attached the generated Include program some where ?

With regards

Manish Kumar

4 REPLIES 4

former_member404244
Active Contributor
0 Kudos

Hi,

Yes we need to use the includes in the module pool program..we need to write logic to populate ZCHNGDOC_WRITE_DOCUMENT .

Regards,

Nagaraj

raymond_giuseppi
Active Contributor
0 Kudos

Yes you must call the FM via the generated include in your update program, change document are programmatically managed. in the "SAVE" form use some CALL FUNCTION IN UPDATE TASK to call the FM that updates database and the FM that creates change documents - look at [Update Techniques|http://help.sap.com/saphelp_nw04/helpdata/en/41/7af4cba79e11d1950f0000e82de14a/frameset.htm] and [BC414|http://www.sap.com/services/education]

- without programming you can fill DBTABLOG via SE11 options

- Also look at [Defining Change Document Objects|http://help.sap.com/SAPHELP_nwmobile71/helpdata/EN/2a/fa018f493111d182b70000e829fbfe/frameset.htm] and [Integrating the functionality into the program|http://help.sap.com/SAPHELP_nwmobile71/helpdata/EN/2a/fa01b6493111d182b70000e829fbfe/frameset.htm]

Regards,

Raymond

PedroGuarita
Active Contributor
0 Kudos

Yes, you need to use the FM ...WRITE_DOCUMENT with the old and new record as parameters. Also, don't forget to check wheter the data elements of the fields you want to keep track of are set for change documents, as only those will generate records in CDPOS.

0 Kudos

Pedro,

Can I use SCDO for standard transactions for example to activate Change log in Classification view?

or SCDO is for Ztables and custom stuff?

Thanks

neo