bp #53050
Related PR: #40695
Problem Summary:
pr #40695 introduced the function `from_iso8601_date`, which parses the
string to get year、mouth、 day, and sets the date value through the
`set_time_unit` function.
Since `set_time_unit` lacks some judgment on mouth, it may get an
illegal date in the end, which may cause core in debug mode.
sql : `select from_iso8601_date('2023-00-01');`
```
F20250709 09:50:14.366984 3587796 vdatetime_value.h:1222] Check failed: date_v2_value_.month_ != 0
*** Check failure stack trace: ***
@ 0x559bd7050d96 google::LogMessage::SendToLog()
@ 0x559bd704d7e0 google::LogMessage::Flush()
@ 0x559bd70515d9 google::LogMessageFatal::~LogMessageFatal()
@ 0x559bc725a570 doris::DateV2Value<>::set_time_unit<>()
@ 0x559bc7257380 doris::vectorized::FromIso8601DateV2::execute()
@ 0x559bc7255a88 doris::vectorized::FunctionOtherTypesToDateType<>::execute_impl()
@ 0x559bc09e0781 doris::vectorized::DefaultExecutable::execute_impl()
@ 0x559bc423aa20 doris::vectorized::PreparedFunctionImpl::_execute_skipped_constant_deal()
@ 0x559bc4234938 doris::vectorized::PreparedFunctionImpl::execute_without_low_cardinality_columns()
@ 0x559bc4233f42 doris::vectorized::PreparedFunctionImpl::default_implementation_for_nulls()
@ 0x559bc423a773 doris::vectorized::PreparedFunctionImpl::_execute_skipped_constant_deal()
@ 0x559bc4234938 doris::vectorized::PreparedFunctionImpl::execute_without_low_cardinality_columns()
@ 0x559bc4234a57 doris::vectorized::PreparedFunctionImpl::execute()
```
### What problem does this PR solve?
Issue Number: close #xxx
Related PR: #xxx
Problem Summary:
### Release note
None
### Check List (For Author)
- Test <!-- At least one of them must be included. -->
- [ ] 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:
https://github.com/apache/doris-website/pull/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:
the PR https://github.com/apache/doris/pull/50310 introduce,
shouldn't change the be version in branch-21, others before
compatibility code will be error
### Release note
None
### Check List (For Author)
- Test <!-- At least one of them must be included. -->
- [ ] 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:
https://github.com/apache/doris-website/pull/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 -->
Boost tokenizer requires explicit "." after "$" to correctly extract
JSON path tokens. Without this, expressions like "$[0].key" cannot be
properly split, causing issues in downstream logic. This commit ensures
a "." is automatically added after "$" to maintain consistent token
parsing behavior.
### What problem does this PR solve?
This PR introduces a UT to prevent unintended changes to the Jsonb
format.
The Jsonb format is a stable data contract and should not be changed
lightly, as it may break backward compatibility or affect persisted
data.
Changes
1. Added a dedicated test case that verifies the binary output of
serialized Jsonb data.
2. The test includes hardcoded reference strings and binary blobs as
golden values to validate serialization output.
3. This ensures any modification to the format will be caught early
during development or code review.
Notes
• Developers should not remove or modify this test without a thorough
review and a strong justification.
• If the serialization format must change, please update the test
accordingly and ensure compatibility is preserved.
Related PR: #xxx
Problem Summary:
### Release note
None
### Check List (For Author)
- Test <!-- At least one of them must be included. -->
- [ ] 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:
https://github.com/apache/doris-website/pull/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 -->
…ght, append_trailing_char_if_absent (#49127)
The url_encode function previously performed a modulus operation on a
signed number. Converting it to an unsigned number will fix the issue.
```
before
mysql> select url_encode('编码');
+----------------------+
| url_encode('编码') |
+----------------------+
| %5.%23%0-%5.%10%/( |
+----------------------+
now
mysql> select url_encode('编码');
+----------------------+
| url_encode('编码') |
+----------------------+
| %E7%BC%96%E7%A0%81 |
+----------------------+
```
The strright function did not calculate the length according to the
number of UTF-8 characters.
```
before
mysql> select strright("你好世界",5);
+----------------------------+
| strright("你好世界",5) |
+----------------------------+
| |
+----------------------------+
now
mysql> select strright("你好世界",5);
+----------------------------+
| strright("你好世界",5) |
+----------------------------+
| 你好世界 |
+----------------------------+
```
he case of inputting a UTF-8 character was not considered.
```
mysql> select append_trailing_char_if_absent('中文', '文');
+-------------------------------------------------+
| append_trailing_char_if_absent('中文', '文') |
+-------------------------------------------------+
| NULL |
+-------------------------------------------------+
now
mysql> select append_trailing_char_if_absent('中文', '文');
+-------------------------------------------------+
| append_trailing_char_if_absent('中文', '文') |
+-------------------------------------------------+
| 中文 |
+-------------------------------------------------+
```
### What problem does this PR solve?
backport:https://github.com/apache/doris/pull/48537
Issue Number: close #xxx
Related PR: #xxx
Problem Summary:
### Release note
None
### Check List (For Author)
- Test <!-- At least one of them must be included. -->
- [ ] 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:
https://github.com/apache/doris-website/pull/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 -->
Pick #49403
If the two arrays have the same non-null elements, they are considered
overlapping, and the result is 1.
If the two arrays have no common non-null elements and either array
contains a null element, the result is null.
Otherwise, the result is 0.
```
select arrays_overlap([1, 2, 3], [1, null]); -- result should be 1
select arrays_overlap([2, 3], [1, null]); -- result should be null
select arrays_overlap([2, 3], [1]); -- result should be 0
```
### What problem does this PR solve?
### What problem does this PR solve?
pick #48944 [fix](arrow) Fix UT DataTypeSerDeArrowTest of
Array/Map/Struct/Bitmap/HLL/Decimal256 types
pick #48398 [fix](arrow) Fix UT DataTypeSerDeArrowTest of Date type
Reverts apache/doris#48729
temp revert this pr for
PartialUpdateInfo::_generate_default_values_for_missing_cids using empty
string , which will make this check fail.
…8872)
https://github.com/apache/doris/pull/48872
before
```
mysql> select STR_TO_DATE (' ', '%Y-%m-%d %H:%i:%s');
+-----------------------------------------+
| STR_TO_DATE (' ', '%Y-%m-%d %H:%i:%s') |
+-----------------------------------------+
| |
+-----------------------------------------+
```
now
```
mysql> select STR_TO_DATE (' ', '%Y-%m-%d %H:%i:%s');
+-----------------------------------------+
| STR_TO_DATE (' ', '%Y-%m-%d %H:%i:%s') |
+-----------------------------------------+
| NULL |
+-----------------------------------------+
```
Problem Summary:
None
- Test <!-- At least one of them must be included. -->
- [x] Regression test
- [x] 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:
- [x] No.
- [ ] Yes. <!-- Explain the behavior change -->
- Does this need documentation?
- [x] No.
- [ ] Yes. <!-- Add document PR link here. eg:
https://github.com/apache/doris-website/pull/1214 -->
- [ ] 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
None
### Check List (For Author)
- Test <!-- At least one of them must be included. -->
- [ ] 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:
https://github.com/apache/doris-website/pull/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 -->
…ke select core (#48625)
fix invalid jsonb value write into segment file which make select core,
so we add a check for jsonb value when convert_to_olap which value will
be written into segment file