jayzhan211 opened a new issue, #8873:
URL: https://github.com/apache/arrow-datafusion/issues/8873
### Describe the bug
array literal with struct occurs error, the reason is that we only consider
Array function as valid type. It seems we should also accept Struct
```rust
if fun == BuiltinScalarFunction::MakeArray {
values.push(value);
} else {
// BuiltinScalarFunction::Struct
return not_impl_err!(
"ScalarFunctions without MakeArray are not
supported: {value}"
);
}
```
### To Reproduce
query error DataFusion error: This feature is not implemented:
ScalarFunctions without MakeArray are not supported: struct\(Utf8\("x"\),
Int64\(1\)\)
select [struct('x', 1)];
### Expected behavior
We can see make_array did the good job here.
query ?
select make_array(struct('x', 1));
----
[{c0: x, c1: 1}]
### 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]