databend
databend copied to clipboard
Improve semantic check of subquery in grouping context
For some invalid subqueries, we should raise reasonable error for them.
- [ ] Subqueries with invalid outer reference from a grouping context:
select (select t.a from t1) from t group by t.a+1. - [ ] Subqueries with nested aggregate functions:
select max(select max(t.a) from t1) from t - ...