auditing-table-statistics

Installation
SKILL.md

Auditing Table Statistics

Audits optimizer table statistics for staleness, missing column coverage, and row count drift to diagnose poor query performance caused by outdated or incomplete statistics. Uses SHOW STATISTICS for read-only SQL analysis of table-level and column-level statistics freshness, entirely without requiring DB Console access.

Complement to profiling-statement-fingerprints: This skill diagnoses optimizer statistics issues; for identifying historically slow queries, see profiling-statement-fingerprints.

Prerequisites

  • SQL connection with any privilege on target tables
  • Automatic statistics collection enabled (default): sql.stats.automatic_collection.enabled = true

Related skills: profiling-statement-fingerprints for historical query analysis, triaging-live-sql-activity for live triage.

Core Concepts

Installs
44
GitHub Stars
10
First Seen
Mar 23, 2026
auditing-table-statistics — cockroachlabs/cockroachdb-skills