Hitachi

Hitachi Advanced Database Setup and Operation Guide


13.3.3 Reducing the execution time of the adbgetcst command

This subsection explains how to reduce the execution time of the adbgetcst command.

Specify the -v option for the adbbuff operand in the server definition before you execute the adbgetcst command. Specifying this option might reduce the execution time of the command. If the -v option has already been specified, you might be able to reduce the execution time of the adbgetcst command by revising the value specified for the option.

Procedure

  1. Estimate the value to be specified for the -v option.

    Estimate the value to be specified for the -v option of the adbbuff server definition operand in 7.2.11 Operands and options related to global buffers (command format). At this time, substitute the value obtained from the following expression for the sql_rthd_num variable, rather than the value specified for the adb_sql_exe_max_rthd_num operand in the server definition:

    value-specified-for-cost-information-collection-option-adb_getcst_rthd_num - 1
  2. Terminate the HADB server.

    Terminate the HADB server by executing the adbstop command.

  3. Change the server definition.

    Add the -v option to the adbbuff operand in the server definition. Alternatively, change the value specified for the -v option. For the -v option, specify the value that you estimated in step 1.

  4. Start the HADB server.

    Execute the adbstart command to start the HADB server.

  5. Execute the adbgetcst command.

  6. Execute the adbstat command to output the global buffer statistical information.

    Make adjustments until the value that is output to DBbuff_tblscan_failed_cnt in the global buffer statistical information output when the adbstat command is executed approaches 0, based on the explanation in (1) Using the global buffer statistical information to reduce the execution time of an SQL statement that performs table scans under 13.2.5 Reducing the execution time of SQL statements that perform table scans. By making these adjustments, you can sometimes reduce the execution time of the adbgetcst command.

    When you read the description in the preceding reference-target subsection, replace an SQL statement that performs table scans with the adbgetcst command.