Neoview SQL Reference Manual (R2.3)

RECOMPUTE
when used, the MVs in the MVGROUP are cleared and repopulated from scratch. Contrast
this with incremental refresh when the RECOMPUTE option is not used. In this case, only
changes since the last refresh are applied.
CANCEL
helps recover from failure situations. In certain cases, reissuing the MAINTAIN operation
may not work. For example, when the system has a disk space issue and the MAINTAIN
operation keeps failing due to insufficient disk space. In such a case, the operation is canceled
and resources are freed up until the bigger issue is resolved.
MVLOG CLEANUP
gives control over cleaning the table logs from entries that are no longer needed. The default
option is WITH MVLOG CLEANUP, where the logs are cleaned at the end of the refresh. If you
want to run the log cleanup outside the refresh window, specify WITHOUT MVLOG CLEANUP
and invoke the utility again with DO ONLY MVLOG CLEANUP outside the refresh window.
This option gives you control over when you clear the logs.
Note that if an ON REQUEST MV is not refreshed, the data in the log tables of the base table
is accumulated and cannot be cleaned up. This is also true for ON REQUEST MVs that were
created but not yet initialized.
For additional information on materialized views, see “CREATE MATERIALIZED VIEW
Statement” (page 60).
Examples of MAINTAIN
Displays all tasks that are done on table t1_090:
maintain table t1_090, all, display;
Displays all tasks that are done on table t1_090 but shows the actual execution:
maintain table t1_090, all;
Refreshes mvgroup MVG_090:
maintain mvgroup MVG_090, refresh;
Reorganizes index T1_090_2:
maintain index T1_090_2, reorg;
Shows the internal SQL statements that will be used for each task:
maintain table t1_090, all, display detail;
Disables all tasks that are allowed to be disabled (reorg table, index, update statistics):
maintain table t1_090, all, disable;
The status will show up as Disabled for the tasks that were disabled by the previous
command.
maintain table t1_090, all, display;
Enables all tasks:
maintain table t1_090, all, enable;
The display shows the status as Scheduled (enabled):
maintain table t1_090, all, display;
Disables update statistics on the specified table:
maintain table t1_090, update statistics, disable;
Enables update statistics on the specified table:
maintain table t1_090, update statistics, enable;
Examples of MAINTAIN invoked with optional task options:
MAINTAIN Command 195