Archiving History Records for Stock Value Tables (MM-IM)

Definition

Archiving object MM_HDEL is used to archive history records for stock value tables in the MM Inventory Management (MM-IM) component .

You can use archiving object PR_ORDER in SAP NetWeaver Information Lifecycle Management . You must have activated the corresponding business functions to do this. The system then also shows the ILM Actions group box. You can use these actions to carry out archiving, for example, where the retention periods stored in the Information Retention Manager can be evaluated. Additionally, you can create snapshots (copies) of data or destroy data that matches the requirements. For more information, see ILM Enhancements for Data Archiving , ILM Actions in the Write Program .

This archiving object was revised in the course of a project to standardize and optimize data archiving. You can use the standardized archiving object by activating the business function Data Archiving: Standardization of Archiving Objects (technical name DA_ARCHOBJ_STANDARD_1 ). For more information, see the business function documentation in the Switch Framework (transaction SFW5).

Use

Note Note

Consider the following SAP Notes:

532734 (Reorganization of history tables for stock in MM)

320665 (Deleting MBEWH records of archived materials)

End of the note.

The stock value tables MBEW , EBEW , and QBEW contain history records. For example, MBEWH is the history record for MBEW and EBEWH is the history record for EBEW . These history records can contain an entry with the relevant stock information for each period. The records are created whenever a change is made to any period-relevant information for the previous period. As a consequence, you cannot read the information for the previous period directly from tables MBEW , EBEW , and QBEW . Instead, you need to interpret and read the history records MBEWH , EBEWH , and QBEWH .

The write program RM07KOHDEL2 archives the following history records:

  • MBEWH (Material valuation - history)

  • QBEWH (Valuation of project stock - history)

  • EBEWH (Valuation of sales order stock - history)

Selecting and Archiving History Records

You can select and archive the history records for stock value tables using the write program RM07KOHDEL2 and according to the following criteria:

R_MATNR Shows the material numbers to be selected.

R_BWKEY Shows the valuation areas to be selected. Check whether you are valuating at plant level or at company code level.

If you are valuating at plant level: Note that all plants must belong to the same company code. This is necessary because the system determines the current period using the company code.

If you are valuating at company code level, then you can only enter one company code. Therefore, you must start a separate archiving session for each company code.

PERIOD LIMITS The system uses the company code to determine the highest archivable period. If you do not want to enter a smaller upper limit, then you can enter the above period. The system ignores any entries that exceed the highest archivable period.

The lower period limit defines the period after which the history records will be selected. If you do not enter a limit here, then the system starts with the oldest period.

Residence Time/Retention Period of Data in the System:

You cannot delete the data from the current period, the previous period, the period before last, or the data from the last period of the previous year.

Example Example

If your periods correspond to the calendar months and the current period is 8, then you cannot delete the data from periods 6 and 7 of the current business year, or period 12 of the previous business year.

End of the example.

Test Run If you only want to simulate the archiving without deleting any data, then you can define here that no archive data should be generated and that no data should be deleted from the database.

Archive Choose this option if you want to create an archive file for the selected data. Note that you can control whether the deletion program is started automatically by making settings in Customizing for transaction AOBJ .

DEL_ONLY Choose this option if you only want to delete the selected data from the database WITHOUT creating an archive file. The data is deleted and cannot be retrieved.

Deleting the Archived History Records

You can delete archived history records from the database using the delete program RM07KARC .