Open kevin-v-ngo opened 2 years ago
@kevin-v-ngo are you planning to spec this out more? Or should I assign someone from SQL Queries to work on it for 23.1?
@rachitgsrivastava, @jordanlewis can you confirm if https://www.cockroachlabs.com/docs/stable/show-statistics.html#output has everything we need for workload replay?
It does not, it also needs the histogram data if we want to make realistic fake data distributions. It would potentially be fine to start with just the counts (the output of show statistics) but it'd be less complete for sure.
SHOW STATISTICS USING JSON
will include the histograms.
Internally there's a PrintTableStats function that gives SHOW STATISTICS USING JSON
with the histograms removed. Maybe we could use that?
We should capture optimizer table statistics used by the planner as defined by the following output (row counts, distinct counts, null counts, etc.): https://www.cockroachlabs.com/docs/stable/show-statistics.html#output
This will enable internal workload replay efforts.
Jira issue: CRDB-18463