Skip to content
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

fix: Allow companion functions when result type is not resolvable given intermediate type #11999

Open
wants to merge 1 commit into
base: main
Choose a base branch
from

Conversation

rui-mo
Copy link
Collaborator

@rui-mo rui-mo commented Jan 2, 2025

The registrations of partial and merge companion functions does not require the
result type is resolvable given intermediate type. This PR removes the
limitations for them.The registration of merge_extract companion function used
to depend on the resolving, and this PR uses the passed-in result type rather
than the resolved from intermediate type.

@facebook-github-bot facebook-github-bot added the CLA Signed This label is managed by the Facebook bot. Authors need to sign the CLA before a PR can be reviewed. label Jan 2, 2025
Copy link

netlify bot commented Jan 2, 2025

Deploy Preview for meta-velox canceled.

Name Link
🔨 Latest commit 3d2f9e5
🔍 Latest deploy log https://app.netlify.com/sites/meta-velox/deploys/677f42032b1ccf0008a6a673

@rui-mo rui-mo force-pushed the wip_merge_extract branch 2 times, most recently from cee024d to 9a4519f Compare January 2, 2025 07:12
@zhztheplayer
Copy link
Contributor

zhztheplayer commented Jan 2, 2025

@rui-mo Thank you for taking this on. I remember we needed to bypass this check as well to make the decimal aggregate functions work. Or we don't need that change anymore?

@Yuhta Yuhta requested a review from kagamiori January 2, 2025 15:13
@rui-mo rui-mo force-pushed the wip_merge_extract branch from 9a4519f to 9911e8f Compare January 8, 2025 09:39
@rui-mo
Copy link
Collaborator Author

rui-mo commented Jan 8, 2025

@zhztheplayer Thanks for the pointer! In Gluten we expect that all the names will end with "_merge_extract," however according to this reasoning, the names may have other suffixes. For instance, we would obtain the names for sum and average as follows. I'll investigate further to see how to incorporate this section with Gluten.

avg_merge_extract_DECIMAL, avg_merge_extract_double
sum_merge_extract_bigint, sum_merge_extract_DECIMAL, sum_merge_extract_double

@zhztheplayer
Copy link
Contributor

@zhztheplayer Thanks for the pointer! In Gluten we expect that all the names will end with "_merge_extract," however according to this reasoning, the names may have other suffixes. For instance, we would obtain the names for sum and average as follows. I'll investigate further to see how to incorporate this section with Gluten.

avg_merge_extract_DECIMAL, avg_merge_extract_double
sum_merge_extract_bigint, sum_merge_extract_DECIMAL, sum_merge_extract_double

Sounds reasonable. Look forward to a solution here. Thanks!

@rui-mo rui-mo force-pushed the wip_merge_extract branch from 9911e8f to 3d2f9e5 Compare January 9, 2025 03:26
@rui-mo rui-mo marked this pull request as ready for review January 9, 2025 03:27
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
CLA Signed This label is managed by the Facebook bot. Authors need to sign the CLA before a PR can be reviewed.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants