Information about change documents is stored in the CDHDR (change document header) and CDPOS (change document items) change document tables. This information can be extracted by carrying out the corresponding configuration for the relevant data table (table XML element). Please use the com.idsscheer.ppm.xmlextractortools.extractor.sap2ppm.
ZChangeDocTableNew_sap2ppm class to do this.
Example (extract from table configuration, general file framework)
A configuration with conditions that need to be specified in a table element could look like this:
...
<table name="tablename" classtouse="com.idsscheer.ppm.
xmlextractortools.extractor.sap2ppm.
ZChangeDocTableNew_sap2ppm">
<booleancondition>
<condition fieldname="OBJECTCLAS" logicaloperator="...">
...
</condition>
<condition fieldname="OBJECTID" logicaloperator="...">
...
</condition>
<condition fieldname="TABNAME" logicaloperator="...">
...
</condition>
<condition fieldname="TABKEY" logicaloperator="...">
...
</condition>
<condition fieldname="FNAME" logicaloperator="in">
...
</condition>
</booleancondition>
<pkfield name="OBJECTCLAS"/>
<pkfield name="OBJECTID"/>
<pkfield name="CHANGENR"/>
<pkfield name="TABNAME"/>
<pkfield name="TABKEY"/>
<pkfield name="FNAME"/>
<pkfield name="CHNGIND"/>
<pkfield name="<Field that is used in TABKEY>"
fktablename="<Foreign key table, from
which the field is extracted>"
fkfieldname="<Foreign key table field>"/>
... Other fields used in TABKEY
<fieldtoread name="CDPOS-VALUE_OLD"/>
... Other fields from the CDPOS table
<fieldtoread name="CDHDR-UDATE"/>
... Other fields from the CDHDR table
</table>
...
The combination of values specified in the OBJECTID and TABKEY fields is the same as for the com.idsscheer.ppm.xmlextractortools.extractor.
sap2ppm.ZChangeDocTable_sap2ppm class. A more concrete example is shown below.
Example (extract from a table configuration from the PPM4MM configuration package)
The example configuration is intended to extract the time at which one of the fields for the reasons for blocking logistical invoices was changed:
...
<table name="CDPOS" classtouse="com.idsscheer.ppm.
xmlextractortools.extractor.sap2ppm.
ZChangeDocTableNew_sap2ppm">
<booleancondition>
<condition fieldname="OBJECTCLAS" logicaloperator="eq">
<value>INCOMINGINVOICE</value>
</condition>
<condition fieldname="OBJECTID"
logicaloperator="eq_concatEventAttrValues">
<value>RSEG-BELNR#-#RSEG-GJAHR</value>
</condition>
<condition fieldname="TABNAME" logicaloperator="eq">
<value>RSEG</value>
</condition>
<condition fieldname="TABKEY"
logicaloperator="eq_concatEventAttrValues">
<value> #-#RSEG-BELNR#-#
RSEG-GJAHR#-#RSEG-BUZEI</value>
</condition>
<condition fieldname="FNAME" logicaloperator="in">
<value>SPGRP</value>
<value>SPGRM</value>
<value>SPGRT</value>
<value>SPGRG</value>
<value>SPGRV</value>
<value>SPGRQ</value>
<value>SPGRS</value>
<value>SPGRC</value>
</condition>
</booleancondition>
<pkfield name="OBJECTCLAS"/>
<pkfield name="OBJECTID"/>
<pkfield name="CHANGENR"/>
<pkfield name="TABNAME"/>
<pkfield name="TABKEY"/>
<pkfield name="FNAME"/>
<pkfield name="CHNGIND"/>
<pkfield name="BELNR" fktablename="RSEG"
fkfieldname="BELNR"/>
<pkfield name="GJAHR" fktablename="RSEG"
fkfieldname="GJAHR"/>
<pkfield name="BUZEI" fktablename="RSEG"
fkfieldname="BUZEI"/>
</table>
...
A system event generated with this example configuration could look like this:
...
<event>
<attribute type="CDPOS-CHANGE_USER_1">HUETT</attribute>
<attribute type="CDPOS-FIRST_CHANGE_DATE">20010220
</attribute>
<attribute type="CDPOS-FIRST_CHANGE_TIME">154943
</attribute>
<attribute type="CDPOS-LAST_CHANGE_DATE">20010220
</attribute>
<attribute type="CDPOS-LAST_CHANGE_TIME">154943
</attribute>
<attribute type="CDPOS-NUM_OF_CHANGES_USER_1">1
</attribute>
<attribute type="CDPOS-SUM_OF_CHANGES">1</attribute>
...
<event>
...