izveigor opened a new issue, #6993: URL: https://github.com/apache/arrow-datafusion/issues/6993
### Describe the bug Follow on to https://github.com/apache/arrow-datafusion/pull/6384 Follow on to https://github.com/apache/arrow-datafusion/issues/6804 `make_array` can not form columns with lists. When we are working with scalars, that problem does not appear. But the situation changes dramatically when we use columns. With columns `make_array` function always returns only 1 row. ### To Reproduce ``` ❯ select * from arrays_values_without_nulls; +------------------------------------------+---------+---------+---------+ | column1 | column2 | column3 | column4 | +------------------------------------------+---------+---------+---------+ | [1, 2, 3, 4, 5, 6, 7, 8, 9, 10] | 1 | 1 | , | | [11, 12, 13, 14, 15, 16, 17, 18, 19, 20] | 12 | 2 | . | | [21, 22, 23, 24, 25, 26, 27, 28, 29, 30] | 23 | 3 | - | | [31, 32, 33, 34, 35, 26, 37, 38, 39, 40] | 34 | 4 | ok | +------------------------------------------+---------+---------+---------+ 4 rows in set. Query took 0.015 seconds. ❯ select make_array(column1) from arrays_values_without_nulls; +-------------------------------------------------+ | make_array(arrays_values_without_nulls.column1) | +-------------------------------------------------+ | [[1, 2, 3, 4, 5, 6, 7, 8, 9, 10]] | +-------------------------------------------------+ 1 row in set. Query took 0.017 seconds. ``` ### Expected behavior ``` ❯ select * from arrays_values_without_nulls; +------------------------------------------+---------+---------+---------+ | column1 | column2 | column3 | column4 | +------------------------------------------+---------+---------+---------+ | [1, 2, 3, 4, 5, 6, 7, 8, 9, 10] | 1 | 1 | , | | [11, 12, 13, 14, 15, 16, 17, 18, 19, 20] | 12 | 2 | . | | [21, 22, 23, 24, 25, 26, 27, 28, 29, 30] | 23 | 3 | - | | [31, 32, 33, 34, 35, 26, 37, 38, 39, 40] | 34 | 4 | ok | +------------------------------------------+---------+---------+---------+ 4 rows in set. Query took 0.015 seconds. ❯ select make_array(column1) from arrays_values_without_nulls; +-------------------------------------------------+ | make_array(arrays_values_without_nulls.column1) | +-------------------------------------------------+ | [[1, 2, 3, 4, 5, 6, 7, 8, 9, 10]] | | [[11, 12, 13, 14, 15, 16, 17, 18, 19, 20]] | | [[21, 22, 23, 24, 25, 26, 27, 28, 29, 30]] | | [[31, 32, 33, 34, 35, 36, 37, 38, 39, 40]] | +-------------------------------------------------+ 1 row in set. Query took 0.017 seconds. ``` ### Additional context _No response_ -- This is an automated message from the Apache Git Service. To respond to the message, please log on to GitHub and use the URL above to go to the specific comment. To unsubscribe, e-mail: [email protected] For queries about this service, please contact Infrastructure at: [email protected]
