Uh oh!
There was an error while loading. Please reload this page.
[Feature](func) Support function QUANTILE_STATE_TO/FROM_BASE64 - #59607
[Feature](func) Support function QUANTILE_STATE_TO/FROM_BASE64#59607linrrzqqq wants to merge 1 commit into
Conversation
Thearas
commented
Jan 6, 2026
Thank you for your contribution to Apache Doris. Please clearly describe your PR:
|
Uh oh!
There was an error while loading. Please reload this page.
linrrzqqq
commented
Jan 6, 2026
run buildall |
hello-stephen
commented
Jan 6, 2026
BE UT Coverage ReportIncrement line coverage Increment coverage report
|
There was a problem hiding this comment.
Pull request overview
This PR adds two new SQL functions quantile_state_to_base64 and quantile_state_from_base64 to enable serialization and deserialization of quantile state objects to/from base64-encoded strings, facilitating storage and transmission of quantile state data.
Key Changes:
- Added
quantile_state_to_base64function to convert QUANTILE_STATE objects to base64 strings - Added
quantile_state_from_base64function to convert base64 strings back to QUANTILE_STATE objects - Implemented comprehensive test coverage including unit tests and regression tests
Reviewed changes
Copilot reviewed 9 out of 9 changed files in this pull request and generated 1 comment.
Show a summary per file
| File | Description |
|---|---|
fe/fe-core/src/main/java/org/apache/doris/nereids/trees/expressions/functions/scalar/QuantileStateToBase64.java | Frontend implementation for quantile_state_to_base64 function with PropagateNullable semantics |
fe/fe-core/src/main/java/org/apache/doris/nereids/trees/expressions/functions/scalar/QuantileStateFromBase64.java | Frontend implementation for quantile_state_from_base64 function with AlwaysNullable semantics |
fe/fe-core/src/main/java/org/apache/doris/nereids/trees/expressions/visitor/ScalarFunctionVisitor.java | Added visitor methods for the new quantile state functions |
fe/fe-core/src/main/java/org/apache/doris/catalog/BuiltinScalarFunctions.java | Registered the new quantile state functions in the function registry |
be/src/vec/functions/function_quantile_state.cpp | Backend implementation of the serialization and deserialization logic with base64 encoding/decoding |
be/test/vec/function/function_test_util.cpp | Added QuantileState type support to the function testing framework |
be/test/vec/function/function_quantile_state_test.cpp | Comprehensive unit tests covering empty states, single/multi-value states, explicit states, and round-trip conversions |
regression-test/suites/query_p0/sql_functions/quantile_state_functions/test_quantile_state_function.groovy | End-to-end regression tests covering NULL handling, invalid inputs, and round-trip conversions |
regression-test/data/query_p0/sql_functions/quantile_state_functions/test_quantile_state_function.out | Expected output for regression tests |
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
Uh oh!
There was an error while loading. Please reload this page.
PR approved by at least one committer and no changes requested. |
PR approved by anyone and no changes requested. |
### What problem does this PR solve? Issue Number: close #xxx Related PR: #59607 Problem Summary: ### Release note None ### Check List (For Author) - Test <!-- At least one of them must be included. --> - [x] Regression test - [ ] Unit Test - [ ] Manual test (add detailed scripts or steps below) - [ ] No need to test or manual test. Explain why: - [ ] This is a refactor/code format and no logic has been changed. - [ ] Previous test can cover this change. - [ ] No code files have been changed. - [ ] Other reason <!-- Add your reason? --> - Behavior changed: - [ ] No. - [ ] Yes. <!-- Explain the behavior change --> - Does this need documentation? - [ ] No. - [ ] Yes. <!-- Add document PR link here. eg: apache/doris-website#1214 --> ### Check List (For Reviewer who merge this PR) - [ ] Confirm the release note - [ ] Confirm test cases - [ ] Confirm document - [ ] Add branch pick label <!-- Add branch pick label that this PR should merge into -->
### What problem does this PR solve? Issue Number: close #xxx Related PR: #59607 Problem Summary: ### Release note None ### Check List (For Author) - Test <!-- At least one of them must be included. --> - [x] Regression test - [ ] Unit Test - [ ] Manual test (add detailed scripts or steps below) - [ ] No need to test or manual test. Explain why: - [ ] This is a refactor/code format and no logic has been changed. - [ ] Previous test can cover this change. - [ ] No code files have been changed. - [ ] Other reason <!-- Add your reason? --> - Behavior changed: - [ ] No. - [ ] Yes. <!-- Explain the behavior change --> - Does this need documentation? - [ ] No. - [ ] Yes. <!-- Add document PR link here. eg: apache/doris-website#1214 --> ### Check List (For Reviewer who merge this PR) - [ ] Confirm the release note - [ ] Confirm test cases - [ ] Confirm document - [ ] Add branch pick label <!-- Add branch pick label that this PR should merge into -->
…e#59664) ### What problem does this PR solve? Issue Number: close #xxx Related PR: apache#59607 Problem Summary: ### Release note None ### Check List (For Author) - Test <!-- At least one of them must be included. --> - [x] Regression test - [ ] Unit Test - [ ] Manual test (add detailed scripts or steps below) - [ ] No need to test or manual test. Explain why: - [ ] This is a refactor/code format and no logic has been changed. - [ ] Previous test can cover this change. - [ ] No code files have been changed. - [ ] Other reason <!-- Add your reason? --> - Behavior changed: - [ ] No. - [ ] Yes. <!-- Explain the behavior change --> - Does this need documentation? - [ ] No. - [ ] Yes. <!-- Add document PR link here. eg: apache/doris-website#1214 --> ### Check List (For Reviewer who merge this PR) - [ ] Confirm the release note - [ ] Confirm test cases - [ ] Confirm document - [ ] Add branch pick label <!-- Add branch pick label that this PR should merge into -->
What problem does this PR solve?
Issue Number: close #xxx
Related PR: #xxx
Problem Summary:
Release note
doc:apache/doris-website#3279
None
Check List (For Author)
Test
Behavior changed:
Does this need documentation?
Check List (For Reviewer who merge this PR)