VMS Help  —  RMU72  Insert Optimizer Statistics, Examples
    Example 1

    The following example:

    1. Collects workload statistics for the JOB_HISTORY table using
       the RMU Collect Optimizer_Statistics command

    2. Deletes the statistics for one of the JOB_HISTORY workload
       column groups

    3. Inserts the statistics that were just deleted into the
       RDB$WORKLOAD system table using the RMU Insert Optimizer_
       Statistics command

    4. Displays the current data stored in the RDB$WORKLOAD table for
       the JOB_HISTORY table using the RMU Show Optimizer_Statistics
       command

    $ RMU/COLLECT OPTIMIZER_STATISTICS MF_PERSONNEL.RDB -
    _$ /TABLE=(JOB_HISTORY)/STATISTICS=(WORKLOAD)/LOG
    Start loading tables... at  3-JUL-1996 10:54:04.16
    Done loading tables.... at  3-JUL-1996 10:54:04.69
    Start collecting workload stats... at  3-JUL-1996 10:54:06.76
    Maximum memory required (bytes) = 6810
    Done collecting workload stats.... at  3-JUL-1996 10:54:07.64
    Start calculating stats... at  3-JUL-1996 10:54:07.84
    Done calculating stats.... at  3-JUL-1996 10:54:07.86
    Start writing stats... at  3-JUL-1996 10:54:09.34

    ---------------------------------------------------------------------

    Optimizer Statistics collected for table : JOB_HISTORY

      Workload Column group  :      EMPLOYEE_ID
      Duplicity factor       : 2.7400000
      Null factor            : 0.0000000

      Workload Column group  :    EMPLOYEE_ID,  JOB_CODE,     JOB_START,
    JOB_END,        DEPARTMENT_CODE,        SUPERVISOR_ID
      Duplicity factor       : 1.5930233
      Null factor            : 0.3649635
    Done writing stats.... at  3-JUL-1996 10:54:09.90
    $ RMU/DELETE OPTIMIZER_STATISTICS MF_PERSONNEL.RDB  -
    _$ /TABLE=(JOB_HISTORY)/COLUMN_GROUP=(EMPLOYEE_ID,JOB_CODE, -
    _$ JOB_START,JOB_END,DEPARTMENT_CODE,SUPERVISOR_ID)/LOG
    Changing RDB$SYSTEM area to READ_WRITE.
    Workload column group deleted for JOB_HISTORY :         EMPLOYEE_ID,
    JOB_CODE,       JOB_START,      JOB_END,        DEPARTMENT_CODE,
    SUPERVISOR_ID
    $ !
    $ RMU/INSERT OPTIMIZER_STATISTICS MF_PERSONNEL.RDB -
    _$ /TABLE=(JOB_HISTORY) /COLUMN_GROUP=(EMPLOYEE_ID,JOB_CODE, -
    _$ JOB_START,JOB_END,DEPARTMENT_CODE,SUPERVISOR_ID) -
    _$ /DUPLICITY_FACTOR=(1.5930233)/NULL_FACTOR=(0.3649635)/LOG
    Changing RDB$SYSTEM area to READ_WRITE.
    Workload column group inserted for JOB_HISTORY :        EMPLOYEE_ID,
    JOB_CODE,       JOB_START,      JOB_END,        DEPARTMENT_CODE,
    SUPERVISOR_ID
    $ !
    $ RMU/SHOW OPTIMIZER_STATISTICS MF_PERSONNEL.RDB -
    _$ /TABLE=(JOB_HISTORY)/STATISTICS=(WORKLOAD)/LOG

    --------------------------------------------------------------------

    Optimizer Statistics for table : JOB_HISTORY

      Workload Column group  :      EMPLOYEE_ID
      Duplicity factor       : 2.7400000
      Null factor            : 0.0000000
      First created time     :  3-JUL-1996 10:37:36.43
      Last collected time    :  3-JUL-1996 10:54:09.62

      Workload Column group  :    EMPLOYEE_ID,  JOB_CODE,     JOB_START,
    JOB_END,        DEPARTMENT_CODE,        SUPERVISOR_ID
      Duplicity factor       : 1.5930233
      Null factor            : 0.3649635
      First created time     :  3-JUL-1996 10:57:47.65
      Last collected time    :  3-JUL-1996 10:57:47.65
Close Help