It is required to delete logs to avoid table overflow of Application Log database.
When you delete process messages in the process message monitor or by means of deletion program RCOCB009 (Transaction CO62), the logs for the process messages are not deleted if the process message was sent to process message destination PI01 'Process message record'.
When sending to process message destination PI01, you create a copy of the process message in the process message record for additional evaluation and for archiving in the process data documentation or in the batch record.
All process message logs are inherited to this copy and archived together with the batch record or with the process data documentation. After you archive the respective process order, the copy of the process message is deleted including the process message logs. For more information on the function of process message destination PI01 and on archiving process orders, see the IMG documentation and the R/3 library.
To keep the number of the process message logs in the system small, proceed as follows:
1. Check whether it is actually required that you send process messages to process message destination PI01. This is only useful if you want to evaluate the data of these process messages using the process data evaluation, or if the process message data including the logs should be part of the process data documentation or the batch record. Remove the process message destination PI01 for the process message categories to which the above-mentioned criteria do not apply. You can activate the process message destination PI01 later again.
2. If you want to continue sending process messages to process message destination PI01, archive your process orders on a regular basis. The process message copies and the logs in the process message record are also deleted by archiving.
3. If you cannot execute the two above-mentioned measures, create program YCOCB012 in your system as described under 'Corrections'. The program is used to delete logs, independent of the status of the process message and independent of whether the process message has been sent to PI01. In addition to logs for process messages, you can also delete logs for control recipes or delete logs for the deletion program for process messages when you use YCOCB009.
Notes on program YCOCB012:
With program YCOCB012, you can directly delete the logs of the application log for the following objects (providing the logs have reached a certain age):
a) Process messages
b) Control recipes
c) Deletion reports for process messages
Consider that this program deletes the logs without additional check of the objects in question (that is, without checking the latest status of process messages or control recipes and without checking the further usage, for example, in the process message record). The deletion is executed on a cross-plant level. For executing the program, you need an authorization for the deletion of logs of the application log (authorization object: S_APPL_LOG).
The selection parameters of the program have the following meaning:
use this entry to specify the minimum age (in days) of the logs to be deleted. Only process messages with a creation date that is before the number of the days entered are selected.
Here, specify the object to which the logs should be deleted. You can select one of the following objects:
COMS - Process messages
COCR - Control recipes
COMD - Logs for the deletion program for process messages