ClickHouse/dbms/tests/queries/0_stateless/00409_shard_limit_by.reference
Constantin S. Pan cbc0f56af1 Mark all input columns in LIMIT BY as required output
The query analyzer only marks the actual arguments of LIMIT BY as required
output for the LimitBy step in the pipeline. This is fine, unless the query is
distributed, in which case the first stage might remove a column that is used
at the second stage (e.g. for ORDER BY) but is not part of the final select.

Prevent removal of any columns in LimitBy by marking all input columns as
required output.
2019-05-24 09:53:09 +01:00

28 lines
89 B
Plaintext

1
1
3
3
4
4
5
7
7
1 2
3 3
4 2
5 1
7 4
1 John
3 Mary
4 Mary
0
0
0
1
100
100
101
101
102
1