Synopsis
Drops and/or builds database indexes that are defined in the WhereScape RED metadata.
Description
Drops and/or builds indexes for a specified table or a specified index. Only indexes that are defined in the WhereScape RED metadata are supported. Typically, this routine is used by a WhereScape RED Scheduler and RED-generated procedures to automatically maintain indexes. However, it is also valid for user-defined custom procedures/scripts to execute this routine to control when indexes are dropped and/or created.
Input
Input | Description |
---|---|
Common Input | Includes all 5 inputs of the Callable Routines Common Input. |
Table Name | Table Name to process the relevant indexes of. Note The Table Name is ignored when the optional Index Name is specified. |
Optional Build Arguments [ORACLE only] | Optional arguments related to building indexes [ORACLE only]: TABLESPACE=XYZ will override the default tablespace name and use the specified tablespace name. e.g. 'TABLESPACE=non_default_tablespace'. Typically, the TABLESPACE argument is used to build indexes in a partition-specific tablespace. |
Index Name | Optional Index Name to only process the specified index. When NOT specified all the relevant indexes of the table are processed. Note
|
Index Action | Action that specifies whether indexes are dropped or built and what types of indexes are applicable:
|
Output
Output | Description |
---|---|
Result Number | Output Result Number:
|
Note
Ws_Maintain_Indexes does NOT include a Return Code or Return Message like most of the WhereScape RED Callable routines, but it does output a Result Number.