Analysis of DB2 table statistics (1)

Source: Internet
Author: User
Tags types of tables

This article will introduce you to the description of how to collect statistics on various types of tables in the DB2 database for your reference. If you are interested in this, please take a look and I believe it will help you.

DB2 provides three command tools to reorganize and analyze table data:
REORGCHK
REORG
RUNSTAT

The statistical information of objects is collected in (1). Here, the statistical information can be used to diagnose the physical storage of objects.

2. REORGCHK: physical storage of diagnostic objects

>-REORGCHK ---- + ------------------------------- + ------------------------------------ + <
|-UPDATE -- |.-USER -------. -- |
'-- +-CURRENT-+ --- STATISTICS -- ''-on table -- +-SYSTEM ----- + --'
+-ALL -------- +
'-Table-name -'

The on schema option is added to the V8 version of UDB.

Update statistics: Call RUNSTATS to analyze the table,
Then, the system diagnoses whether to reorganize the table based on the statistical information.
Current statistics: Use existing STATISTICS to diagnose whether to reorganize the table

On table user: All Tables of the current USER
On table system: All Tables of SYSTEM
On table all: ALL Tables of the current db
On table table-name: table with the specified name


Related Article

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.