Enable column pruning for TiFlash plans regardless of `tidb_enforce_mpp`
Open
planner/cascades
sig/planner
type/enhancement
- Dominant language
- Go
- Stars
- 40.5k
- Forks
- 6.2k
- PR merge metrics
- PR metrics pending
Description
## Enhancement
https://github.com/pingcap/tidb/blob/55cf58bf1681fe1d584e95cede4fa49c7197682a/pkg/planner/core/operator/logicalop/logical_datasource.go#L225-L237
In the current implementation, column pruning is enabled only when `tidb_enforce_mpp` is set to true. This condition is too restrictive, as many users do not enable this flag. The restriction should be removed so that column pruning is always enabled for TiFlash plans, regardless of the `tidb_enforce_mpp` variable.
Contributor guide
Assessment
This issue has not been assessed yet.