Purge planning data

The purge planning data process deletes planning data from SCV tables. This process is implemented using the PURGE_PLANNING_DATA program.

The PURGE_PLANNING_DATA program considers these input parameters:

TABLE_NAME
The name of the table to be deleted.
Note: If this parameter is specified:
  • An existing entry must be available with the specified table name in the SZ_REG_TABLE table. An error message is logged, and the execution is stopped if an entry with the specified table_name value is not available in the SZ_REG_TABLE table.
  • Only one of the TABLE_NAME, TABLE_GROUP_NAME, or TABLE_AREA can be used at a time. An error message is logged, and the execution is stopped if more than one parameter is specified.
TABLE_GROUP_NAME
The name of the table group to be deleted.
Note: If this parameter is specified:
  • An existing entry must be available in the SZ_REG_TABLE_GROUP table. An error message is logged, and the execution is stopped if the entry with the specified table_group_name value is not available in the SZ_REG_TABLE_GROUP table.
  • Only one of the TABLE_NAME, TABLE_GROUP_NAME, or TABLE_AREA can be used at a time. An error message is logged, and the execution is stopped if more than one parameter is specified.
TABLE_AREA
The name of the table area to be deleted.
Note: If this parameter is specified:
  • An existing entry must be available in the SZ_REG_TABLE table. An error message is logged, and the execution is stopped if the entry with the specified table_area value is not available in the SZ_REG_TABLE table.
  • Only one of the TABLE_NAME, TABLE_GROUP_NAME, or TABLE_AREA can be used at a time. An error message is logged, and the execution is stopped if more than one parameter is specified.
SOURCE
The source system from which the planning data is to be deleted.
VERSION_COLUMN
The name of the column that maintains the business object version.
Note: If this parameter is specified:
  • The specified column must be available in all related tables.
  • An error message is logged, and the execution is stopped if the specified column is not available in one or more tables.
VERSIONS_TO_KEEP
The number of business object versions to maintain after deleting.
Note: If this parameter is specified, the VERSION_COLUMN parameter must also be specified.
DATE_COLUMN
The name of the column that contains the reference date to delete older data.
Note: If this parameter is specified:
  • The specified column must be available in all related tables.
  • An error message is logged, and the execution is stopped if the specified column is not available in one or more tables.
DAYS_TO_KEEP
The number of days data to retain.
Note: If this parameter is specified, the DATE_COLUMN parameter must be specified.
INCLUDE_XREF_TABLES
Indicates whether xref tables must also be deleted.
Note: By default, this option is set to Off.
PURGE_SCOPE
Determine the tables that must be considered during deletion. This parameter is only considered when the specified table is a core table. Possible values:
  • 0: All tables. The core and extension tables are included, if available.
  • 1: Only the base table in scope. Selected by default.
  • 2: Only the extension table is included.
Note: 
  • If the specified value is greater than 2, an error message is logged, and the execution is stopped.
  • If the PURGE_SCOPE value is set to 0 or 2, and the VERSION_COLUMN and DATE_COLUMN parameters are specified, the specified version and date columns must be available in the related extension table. Else, an error is logged, and the execution is stopped.

This table lists the default values for the input parameters of the PURGE_PLANNING_DATA program:

Parameter Default value Description Possible values
SOURCE Program scope parameter: Source.
TABLE_AREA This must be a valid table in SCV Table Registry.
TABLE_GROUP_NAME Program scope parameter: Table Group Name. This must be a valid name in SCV Table Groups.
TABLE_NAME Program scope parameter: Table Name. This must be a valid table name in SCV Table Registry.