-
Notifications
You must be signed in to change notification settings - Fork 1.3k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
support LargeList
for arrow_cast
, support ScalarValue::LargeList
#8290
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thank you @Weijun-H -- this looks very nice 👍
LargeList
for arrow_cast
LargeList
for arrow_cast
, support ScalarValue::LargeList
4f54551
to
991f3af
Compare
@@ -342,7 +346,38 @@ impl PartialOrd for ScalarValue { | |||
None | |||
} | |||
} | |||
(LargeList(arr1), LargeList(arr2)) => { | |||
if arr1.data_type() == arr2.data_type() { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@Weijun-H can you try (in a follow on PR) to use the arrow lt
kernels diectly on the list (rather than calling it on each element)? I can't remember if the kernel knows how to handle things
if list_arr1.len() != list_arr2.len() { | ||
return None; | ||
} | ||
for i in 0..list_arr1.len() { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think the list lengths should always be 1, so I don't really understand why this is iterating (though I see it is just following the pattern of ListArray)
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Maybe you can clean it up in a follow on PR (by asserting the list is length 1)
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I will work on this on the next PR
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think @jayzhan211 is working on this #8253
Thanks again @Weijun-H |
Which issue does this PR close?
Closes #.
Rationale for this change
It is hard to test
LargeList
in sqllogictest #8121, the convenient idea is to usearrow_cast()
instead ofmake_array
What changes are included in this PR?
LargeList
forarrow_cast
ScalarValue::LargeList
ScalarValue::new_large_list
LargeList
for protobufAre these changes tested?
Are there any user-facing changes?