You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@flink.apache.org by "liuyongvs (via GitHub)" <gi...@apache.org> on 2023/07/04 01:53:41 UTC
[GitHub] [flink] liuyongvs commented on pull request #22917: [FLINK-32498][table] Fix the problem of array_max return type, it sho…
liuyongvs commented on PR #22917:
URL: https://github.com/apache/flink/pull/22917#issuecomment-1619348688
hi @hanyuzheng7 , you may don't understand the real problem when you reviewed.
i submit the comments before, just for convenient to review.
if you test empty array in sql-client. you should create function as array_empty using ***. CreateEmptyArray
then select array_max(array_empty())
```
comments:
why not add unit test
new Integer[]{}, because the flink's array constuctor function is different from spark
flink should contain at least 1 args.
spark can contain zero arg, for example array()
but they both can be empty array, for example, udf, user can constuct empty array by themself
```
> Although after adding this test case, all test can pass. But the sql-client also report error.
>
> <img alt="Screenshot 2023-07-03 at 5 20 00 PM" width="980" src="https://user-images.githubusercontent.com/135176127/250695447-f968c8bd-1079-4b19-86d9-4151e9a976ca.png"> <img alt="Screenshot 2023-07-03 at 5 41 38 PM" width="667" src="https://user-images.githubusercontent.com/135176127/250697170-143d69db-6007-4539-b97f-3448d666f37f.png">
--
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: issues-unsubscribe@flink.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org