Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Conversation

aihuaxu
Copy link
Contributor

@aihuaxu aihuaxu commented Apr 30, 2025

Fix up to address the comments in #12847: update the shredding to only apply when all the array elements are of a uniform type instead of using most common type. That will make verification straightforward.

@aihuaxu aihuaxu marked this pull request as ready for review April 30, 2025 00:08
return list(shredType);
}

return null;
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Do you think there are cases where we want to shred an array of mixed types, with each value stored in value as an encoded variant? I'm not sure.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I don't think we will have the case that all the elements will be stored in value since I would expect engines will at least choose a shredding type that matches some of the elements. I think this is more common: by sampling the elements, we choose INT32 as the shredding type while some are strings. If all of theme are in value and they are binary, that doesn't seem to be useful.

@rdblue rdblue merged commit e600345 into apache:main Apr 30, 2025
42 checks passed
@rdblue
Copy link
Contributor

rdblue commented Apr 30, 2025

Thanks, @aihuaxu!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants