隨筆-25  評(píng)論-6  文章-0  trackbacks-0
          Abstract
          When you update table statistics using the RUNSTATS command, it requires that you run the command against each table, one by one. REORGCHK gives you the capability to update the statistics of a group of tables or all the tables in the database, with only one command.
          .
          Contents
          _
          DB2 UDB uses the statistics information in the catalog table to derive the best access plan. The DBA should regularly run the RUNSTATS command to keep the database statistics updated. This procedure will ensure the best performance on queries.

          If you want to update statistics on all the tables or a group of tables in the database, you can use the REORGCHK command with the UPDATE STATISTICS option. This would be run instead of running the RUNSTATS command against each table. The UPDATE STATISTICS option will first call the RUNSTATS routine to update the table statistic. You can then use these new statistics to determine if a reorg is needed.

          The REORGCHK command allows you to update statistics on a group of tables with one command.

          To update all the user and system tables use:

          REORGCHK UPDATE STATISTICS ON TABLE ALL

          To update all the tables of a particular schema use:

          REORGCHK UPDATE STATISTICS on SCHEMA schema_name

          To update all the tables of a particular table system use:

          REORGCHK UPDATE STATISTICS on TABLE SYSTEM
          posted on 2006-06-23 15:19 MyJavaWorld 閱讀(478) 評(píng)論(0)  編輯  收藏

          只有注冊(cè)用戶登錄后才能發(fā)表評(píng)論。


          網(wǎng)站導(dǎo)航:
           
          主站蜘蛛池模板: 个旧市| 叶城县| 大方县| 恩平市| 浦江县| 太和县| 临漳县| 罗定市| 化德县| 南溪县| 高碑店市| 邹平县| 邵东县| 康定县| 崇明县| 株洲县| 平武县| 赤水市| 汾阳市| 扎鲁特旗| 秀山| 榆社县| 泸水县| 卫辉市| 辉南县| 吕梁市| 安宁市| 荔浦县| 灌云县| 迁安市| 岳池县| 长乐市| 壤塘县| 石楼县| 花垣县| 明星| 公主岭市| 临夏县| 多伦县| 三门县| 即墨市|