analyze_table
Refresh a table's index statistics so the query optimizer can choose better execution plans. Supports dry-run preview and audit logging for safe DBA operations.
Instructions
[WRITE][risk=medium] ANALYZE TABLE to refresh index statistics.
No undo; captures prior stats for audit. Takes a brief read lock while sampling. Pass dry_run=True to preview.
Args: table: Table name (optionally schema-qualified). dry_run: If True, preview without running. target: Target name from config; omit for the default.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| table | Yes | ||
| target | No | ||
| dry_run | No |