Skip to content

Make command to create stats #41

Closed

Description

@aersam

We need a way to store table and column stats and update them

Do a single json for all table stats (_stats/tables.json), sorted by table name (or even use it as key). document in skill how to read. also add a get-stats command that reads stats from json for given tables

Maybe a json per table in a subfolder _stats for column stats

Activity

  1. aersam commented on Sep 30, 2026

    @aersam
    ContributorAuthor
  2. aersam commented on Sep 30, 2026

    @aersam
    ContributorAuthor

    PR ready for review: #42 (CI green, version 0.10.0).

    • pgdb update-stats database/ --url ... [--table schema.name] [--exact] [--analyze] writes database/_stats/_tables.json (one sorted file keyed by schema.table) and one database/_stats/<schema.table>.json per table for column stats. A full run prunes dropped tables.
    • pgdb get-stats database/ [schema.table ...] [--no-columns] prints the stored stats as JSON, no DB needed.
    • Documented in the pgdevkit skill.
  3. added a commit that references this issue on Sep 30, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    pr-availableA PR exists that addresses this issue

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions