Archiving in SAP Records Management
Use
You can use archiving to store records that are no longer required in archives and then physically remove them from the database. You can archive all elements that are based on the generic Service Provider backend. These elements are referred to as all documents in the following. You can archive both document content and all of the document's attributes.
Since the document content (that is, the unstructured content in Knowledge Provider) often represents the most significant share of the data volume, this content can be moved to a content server well before the growth of metadata (document attributes) makes archiving necessary. SAP provides a relocation report for this purpose (see Process Flow).
You can archive the logical document (all metadata) using the Archive Development Kit (ADK). Consistency between document content and metadata is therefore assured, even if the content and metadata are in different systems. Once archiving is completed, you still have read access to the documents:
The archiving solution in SAP Records Management is based completely on archiving of the Knowledge Provider (KPro). Archiving is controlled completely by the status and is connected to the SAP Archive Information System. The archiving object for SAP Records Management is called SRMGSP.
Prerequisites
You have Activated the Archiving Functions.
Process
Process Flow Archiving and deletion of SAP Records Management documents takes place in the following asynchronous steps:
Relocation Phase: Moving Document Content from the Database
During the relocation phase, you move the physical documents. This is strictly not part of the actual archiving process.
-
Call transaction SE38 and run program SRM_KPRO_CONTENT_RELOCATION.
An entry screen appears.
-
Enter the necessary data.
During a program run, you can store documents of one element type only. You therefore need to enter the area ID, the RMS ID and the element type ID.
-
To specify which documents are archived, make an entry in Age in Days. All documents as old or older than the age you specify will be archived. If you leave this field blank, all documents of the element type in question are archived.
-
Under Category, specify the Content Repository to which you want to move the documents. (You set up content repositories in the SAP Customizing Implementation Guide under ).
-
You can use the Test Run indicator to define whether the program is run in the test mode or production mode. In test mode, the content is not moved, though you can see how many documents would be archived according to the specified criteria.
-
Run the program.
The program log is displayed. This contains a list of all moved documents. If you have run the program in test mode, each document in the list will be followed by the label Test Run.
Preparation Phase: Flag Documents for Archiving
-
Choose the Preprocessing action in the SARA transaction with the archiving object SRMGSP.
-
Choose Start Date and Spool Parameters and enter the required data.
-
Choose a Variant.
-
The initial screen of a program is displayed.
The input parameters correspond to those for the program SRM_KPRO_PRE_PROGRAM. Enter the area in which documents are to be archived. You can enter the RMS ID and the element type to further restrict your selection. You can use Age in Days to define the archiving time. Under Category, specify the content repository to which you have moved the contents of the documents. The program checks whether the contents of the document are actually situated there. You have defined the content repository where the logical document (metadata) will be archived in the Customizing settings for the ADK.
-
Save your entries.
-
Start the program.
You see the message System has created new preprocessing job. Documents are flagged for archiving by setting the Archivable status.
Archiving Phase Write: Write Data to Archive
The write program writes data from all objects that are archivable according to their status in the archive file that has been defined for the respective archiving object. The system sets the status of the archiving run to Incomplete in Archive Administration in the ADK (transaction SARA).
-
Choose the Write action in the SARA transaction with the archiving object SRMGSP.
-
Choose Start Date and Spool Parameters and enter the required data.
-
Choose a Variant.
-
The initial screen of a program is displayed.
The input parameters correspond to those for the program SRM_KPRO_WRITE_PROGRAM. Enter the area in which documents are to be archived. You can enter the RMS ID and the element type to further restrict your selection. You have defined the documents that are actually moved to the archive in advance.
You can use process control to define whether the report is run in the test mode or production mode. Data is not written to the archive in the test mode. You can however determine how many documents would be written using the criteria specified.
-
Run the program. You see the message System has created new archiving job. Document data with the status Archivable is written in an archive file. The system does not modify the status of the document.
Archiving Phase Delete: Delete Archived Data
The deletion program opens the archive files that were previously created by the write program and reads the data again. These files are flagged by the system to prevent archive files being read several times. The system sets the product status Archived, Locked, and Deleted for objects that were successfully read to the archive.
The system sets the status of the archiving run to Complete in Archive Administration in the ADK (transaction SARA).
-
Choose the Delete action in the SARA transaction with the archiving object SRMGSP.
-
Choose Start Date and Spool Parameters and enter the required data.
-
Choose a Variant.
You can use process control to define whether the program is run in the test mode or production mode. The system does not delete data from the database in the test mode. You can however determine how many cases would be deleted using the criteria specified.
-
Run the program.
You see the message New deletion jobs scheduled. The system now compares the data in the local archive with data in the local database and sets the product status Archived for objects that are found in both the archive and the database. The documents are deleted from the database.
Display Archived Objects in Product Maintenance
There are two different means of displaying documents:
-
In program SRM_KPRO_READ_PROGRAM (see below for details)
-
In the electronic desk in Records Management
Archived documents are still integrated in the history. These are flagged with the label Archived. By double-clicking on a document, you can display it.
To display archived documents using the program SRM_KPRO_READ_PROGRAM, proceed as follows:
-
Choose the Read action in the SARA transaction with the archiving object SRMGSP.
-
Decide whether you want to read the archived documents in the Background or in Dialog.
The system starts program SRM_KPRO_READ_PROGRAM.
-
The dialog box Archive Management: Select Files to Read appears.
This contains a list of all archiving sessions. You can identify archiving sessions using the archiving date and the note. You can select productive archiving sessions using an indicator. Archiving sessions that have been run in test mode are flagged as Failed.
Select an archiving session and choose Continue.
-
You now see a list containing all archived documents in the chosen archiving session. All documents are displayed as folders. If you expand a folder, you can see the versions of the document in the hierarchy level below it. All attributes for the documents are also displayed.

