schema_explorer_reshard
Simulate how a table's rows would distribute across partitions with a candidate shard key, compare it to current skew, and estimate results from a row sample without changing data.
Instructions
Reshard simulation for the Distribution tab: how a table's rows would spread over the partitions with
another shard key (columns), next to the current skew - nothing is changed. Uses the docs' query (GROUP BY the
candidate key, then GROUP BY PARTITION_ID() on the leaves), which scans the whole table: the app runs it only
on an explicit click. sample_rows: estimate from about that many rows (a random sample, scaled up).
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| table | Yes | ||
| columns | Yes | ||
| database | Yes | ||
| sample_rows | No |