cockroachdb / cockroachdb/cockroach
opt: normalize window frames
Open
C-enhancement
E-quick-win
P-3
T-sql-queries
- Dominant language
- Go
- Stars
- 32.5k
- Forks
- 4.1k
- PR merge metrics
- PR metrics pending
Description
We should add norm rules to convert window frames to a canonical form, so that other rules don't have to worry about checking all cases themselves. For example, the default window frame `RANGE BETWEEN UNBOUNDED PRECEDING AND CURRENT ROW` is equivalent to `RANGE BETWEEN UNBOUNDED PRECEDING AND UNBOUNDED FOLLOWING` when there is no `ORDER BY` clause.
Jira issue: CRDB-35316
Contributor guide
Assessment
This issue has not been assessed yet.