-
Notifications
You must be signed in to change notification settings - Fork 7.1k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #32482 from ClickHouse/backport/21.11/32138
Backport #32138 to 21.11: Fix 'APPLY lambda' parsing
- Loading branch information
Showing
5 changed files
with
37 additions
and
9 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
10 changes: 10 additions & 0 deletions
10
tests/queries/0_stateless/02128_apply_lambda_parsing.reference
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,10 @@ | ||
1 | ||
1 | ||
1 | ||
1 | ||
1 | ||
1 | ||
2 | ||
3 | ||
4 | ||
5 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,13 @@ | ||
WITH * APPLY lambda(e); -- { clientError SYNTAX_ERROR } | ||
SELECT * APPLY lambda(); -- { clientError SYNTAX_ERROR } | ||
SELECT * APPLY lambda(1); -- { clientError SYNTAX_ERROR } | ||
SELECT * APPLY lambda(x); -- { clientError SYNTAX_ERROR } | ||
SELECT * APPLY lambda(range(1)); -- { clientError SYNTAX_ERROR } | ||
SELECT * APPLY lambda(range(x)); -- { clientError SYNTAX_ERROR } | ||
SELECT * APPLY lambda(1, 2); -- { clientError SYNTAX_ERROR } | ||
SELECT * APPLY lambda(x, y); -- { clientError SYNTAX_ERROR } | ||
SELECT * APPLY lambda((x, y), 2); -- { clientError SYNTAX_ERROR } | ||
SELECT * APPLY lambda((x, y), x + y); -- { clientError SYNTAX_ERROR } | ||
SELECT * APPLY lambda(tuple(1), 1); -- { clientError SYNTAX_ERROR } | ||
SELECT * APPLY lambda(tuple(x), 1) FROM numbers(5); | ||
SELECT * APPLY lambda(tuple(x), x + 1) FROM numbers(5); |