DB2 Version 9.7 for Linux, UNIX, and Windows

SYSINSTALLOBJECTS procedure

The SYSINSTALLOBJECTS procedure creates or drops the database objects that are required for a specific tool.

Syntax

Read syntax diagramSkip visual syntax diagram
>>-SYSINSTALLOBJECTS--(--tool-name--,--action--,---------------->

>--tablespace-name--,--schema-name--)--------------------------><

The schema is SYSPROC.

Procedure parameters

tool-name
An input argument of type VARCHAR(128) that specifies the name of the tool that is to be loaded, using one of the following values:
  • 'AM' for creating activity monitor objects
  • 'DB2AC' for autonomous computing (health monitor)
  • 'STMG_DBSIZE_INFO' for storage management
  • 'OPT_PROFILES' for creating the optimization profile table
  • 'POLICY' for policy (tables and triggers)
  • 'EXPLAIN' for creating or migrating explain tables
  • 'ASP' for automatically generating statistics profiles
action
An input argument of type CHAR(1) that specifies the action that is to be taken. Valid values are:
C
Create objects.
D
Drop objects.
V
Verify objects.
M
Migrate objects. The M option is only valid when used with the tool name EXPLAIN. This option migrates explain tables that were created in Version 9.5 through Version 9.7 to be compatible with Version 9.7 Fix Pack 1. Explain tables you created in Version 9.7 Fix Pack 1, or later, are not modified.
tablespace-name
An input argument of type VARCHAR(128) that specifies the name of the table space in which the objects are to be created. If a value is not specified, or the value is an empty or blank string, the default user space is used if the tool name is AM. If the tool name is EXPLAIN and the action is M, the input table space name is ignored and the table space is used where the explain tables that are being migrated were created. Otherwise, the SYSTOOLSPACE table space is used. If SYSTOOLSPACE does not already exist, it will be created.
schema-name
Except for 'EXPLAIN' tool-name option, SYSTOOLS is always used as the schema regardless of the schema-name passed as the input parameter.
For 'EXPLAIN' tool-name option, an input schema-name can be passed and the tables are created under the specified schema-name. If no schema-name is passed as the input parameter, SYSTOOLS schema is used.

Authorization

One of the following authorities is required to execute the procedure:
  • EXECUTE privilege on the procedure
  • DATAACCESS authority
  • DBADM authority
  • SQLADM authority

Example

CALL SYSPROC.SYSINSTALLOBJECTS('AM', 'C', CAST (NULL AS VARCHAR(128)),
   CAST (NULL AS VARCHAR(128)))