Coverage Report

Created: 2025-05-05 03:34

/root/doris/be/src/vec/functions/dictionary.cpp
Line
Count
Source (jump to first uncovered line)
1
// Licensed to the Apache Software Foundation (ASF) under one
2
// or more contributor license agreements.  See the NOTICE file
3
// distributed with this work for additional information
4
// regarding copyright ownership.  The ASF licenses this file
5
// to you under the Apache License, Version 2.0 (the
6
// "License"); you may not use this file except in compliance
7
// with the License.  You may obtain a copy of the License at
8
//
9
//   http://www.apache.org/licenses/LICENSE-2.0
10
//
11
// Unless required by applicable law or agreed to in writing,
12
// software distributed under the License is distributed on an
13
// "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
14
// KIND, either express or implied.  See the License for the
15
// specific language governing permissions and limitations
16
// under the License.
17
18
#include "vec/functions/dictionary.h"
19
20
#include <variant>
21
22
#include "runtime/thread_context.h"
23
#include "vec/columns/column.h"
24
#include "vec/data_types/data_type_ipv4.h"
25
#include "vec/data_types/data_type_nullable.h"
26
27
namespace doris::vectorized {
28
29
IDictionary::IDictionary(std::string name, std::vector<DictionaryAttribute> attributes)
30
694
        : _dict_name(std::move(name)), _attributes(std::move(attributes)) {
31
1.39k
    for (size_t i = 0; i < _attributes.size(); i++) {
32
700
        const auto& name = _attributes[i].name;
33
700
        if (_name_to_attributes_index.contains(name)) {
34
0
            throw doris::Exception(ErrorCode::INVALID_ARGUMENT,
35
0
                                   "The names of attributes should not have duplicates : {}", name);
36
0
        }
37
700
        _name_to_attributes_index[name] = i;
38
700
    }
39
694
}
40
41
694
IDictionary::~IDictionary() {
42
694
    if (_mem_tracker) {
43
5
        SCOPED_SWITCH_THREAD_MEM_TRACKER_LIMITER(_mem_tracker);
44
5
        std::vector<ValueData> {}.swap(_values_data);
45
5
        std::string {}.swap(_dict_name);
46
5
        std::vector<DictionaryAttribute> {}.swap(_attributes);
47
5
        _name_to_attributes_index.clear();
48
5
    }
49
694
}
50
51
0
bool IDictionary::has_attribute(const std::string& name) const {
52
0
    return _name_to_attributes_index.contains(name);
53
0
}
54
55
2.07k
size_t IDictionary::attribute_index(const std::string& name) const {
56
2.07k
    auto it = _name_to_attributes_index.find(name);
57
2.07k
    if (it == _name_to_attributes_index.end()) {
58
0
        throw doris::Exception(ErrorCode::INVALID_ARGUMENT, "no this attribute : {}", name);
59
0
    }
60
2.07k
    size_t idx = it->second;
61
2.07k
    return idx;
62
2.07k
}
63
64
0
bool IDictionary::attribute_is_nullable(size_t idx) const {
65
0
    return _attributes[idx].type->is_nullable();
66
0
}
67
68
std::variant<std::false_type, std::true_type> IDictionary::attribute_nullable_variant(
69
1.03k
        size_t idx) const {
70
1.03k
    return vectorized::make_bool_variant(_attributes[idx].type->is_nullable());
71
1.03k
}
72
73
0
DataTypePtr IDictionary::get_attribute_type(const std::string& name) const {
74
0
    auto it = _name_to_attributes_index.find(name);
75
0
    if (it == _name_to_attributes_index.end()) {
76
0
        throw doris::Exception(ErrorCode::INVALID_ARGUMENT, "no this attribute : {}", name);
77
0
    }
78
0
    size_t idx = it->second;
79
0
    return remove_nullable(_attributes[idx].type);
80
0
}
81
82
7
size_t IDictionary::allocated_bytes() const {
83
7
    size_t bytes = 0;
84
7
    for (const auto& value_data : _values_data) {
85
7
        std::visit(
86
7
                [&](auto&& arg) {
87
7
                    const auto* column = arg.get();
88
7
                    bytes += column->allocated_bytes();
89
7
                    if (arg.get_null_map()) {
90
0
                        bytes += arg.get_null_map()->allocated_bytes();
91
0
                    }
92
7
                },
Unexecuted instantiation: dictionary.cpp:_ZZNK5doris10vectorized11IDictionary15allocated_bytesEvENK3$_0clIRKNS1_14ColumnWithTypeINS0_14DataTypeNumberIhEEEEEEDaOT_
Unexecuted instantiation: dictionary.cpp:_ZZNK5doris10vectorized11IDictionary15allocated_bytesEvENK3$_0clIRKNS1_14ColumnWithTypeINS0_14DataTypeNumberIaEEEEEEDaOT_
Unexecuted instantiation: dictionary.cpp:_ZZNK5doris10vectorized11IDictionary15allocated_bytesEvENK3$_0clIRKNS1_14ColumnWithTypeINS0_14DataTypeNumberIsEEEEEEDaOT_
dictionary.cpp:_ZZNK5doris10vectorized11IDictionary15allocated_bytesEvENK3$_0clIRKNS1_14ColumnWithTypeINS0_14DataTypeNumberIiEEEEEEDaOT_
Line
Count
Source
86
7
                [&](auto&& arg) {
87
7
                    const auto* column = arg.get();
88
7
                    bytes += column->allocated_bytes();
89
7
                    if (arg.get_null_map()) {
90
0
                        bytes += arg.get_null_map()->allocated_bytes();
91
0
                    }
92
7
                },
Unexecuted instantiation: dictionary.cpp:_ZZNK5doris10vectorized11IDictionary15allocated_bytesEvENK3$_0clIRKNS1_14ColumnWithTypeINS0_14DataTypeNumberIlEEEEEEDaOT_
Unexecuted instantiation: dictionary.cpp:_ZZNK5doris10vectorized11IDictionary15allocated_bytesEvENK3$_0clIRKNS1_14ColumnWithTypeINS0_14DataTypeNumberInEEEEEEDaOT_
Unexecuted instantiation: dictionary.cpp:_ZZNK5doris10vectorized11IDictionary15allocated_bytesEvENK3$_0clIRKNS1_14ColumnWithTypeINS0_14DataTypeNumberIfEEEEEEDaOT_
Unexecuted instantiation: dictionary.cpp:_ZZNK5doris10vectorized11IDictionary15allocated_bytesEvENK3$_0clIRKNS1_14ColumnWithTypeINS0_14DataTypeNumberIdEEEEEEDaOT_
Unexecuted instantiation: dictionary.cpp:_ZZNK5doris10vectorized11IDictionary15allocated_bytesEvENK3$_0clIRKNS1_14ColumnWithTypeINS0_12DataTypeIPv4EEEEEDaOT_
Unexecuted instantiation: dictionary.cpp:_ZZNK5doris10vectorized11IDictionary15allocated_bytesEvENK3$_0clIRKNS1_14ColumnWithTypeINS0_12DataTypeIPv6EEEEEDaOT_
Unexecuted instantiation: dictionary.cpp:_ZZNK5doris10vectorized11IDictionary15allocated_bytesEvENK3$_0clIRKNS1_14ColumnWithTypeINS0_14DataTypeStringEEEEEDaOT_
Unexecuted instantiation: dictionary.cpp:_ZZNK5doris10vectorized11IDictionary15allocated_bytesEvENK3$_0clIRKNS1_14ColumnWithTypeINS1_20DictDataTypeString64EEEEEDaOT_
Unexecuted instantiation: dictionary.cpp:_ZZNK5doris10vectorized11IDictionary15allocated_bytesEvENK3$_0clIRKNS1_14ColumnWithTypeINS0_14DataTypeDateV2EEEEEDaOT_
Unexecuted instantiation: dictionary.cpp:_ZZNK5doris10vectorized11IDictionary15allocated_bytesEvENK3$_0clIRKNS1_14ColumnWithTypeINS0_18DataTypeDateTimeV2EEEEEDaOT_
Unexecuted instantiation: dictionary.cpp:_ZZNK5doris10vectorized11IDictionary15allocated_bytesEvENK3$_0clIRKNS1_14ColumnWithTypeINS0_15DataTypeDecimalINS0_7DecimalIiEEEEEEEEDaOT_
Unexecuted instantiation: dictionary.cpp:_ZZNK5doris10vectorized11IDictionary15allocated_bytesEvENK3$_0clIRKNS1_14ColumnWithTypeINS0_15DataTypeDecimalINS0_7DecimalIlEEEEEEEEDaOT_
Unexecuted instantiation: dictionary.cpp:_ZZNK5doris10vectorized11IDictionary15allocated_bytesEvENK3$_0clIRKNS1_14ColumnWithTypeINS0_15DataTypeDecimalINS0_12Decimal128V3EEEEEEEDaOT_
Unexecuted instantiation: dictionary.cpp:_ZZNK5doris10vectorized11IDictionary15allocated_bytesEvENK3$_0clIRKNS1_14ColumnWithTypeINS0_15DataTypeDecimalINS0_7DecimalIN4wide7integerILm256EiEEEEEEEEEEDaOT_
93
7
                value_data);
94
7
    }
95
7
    return bytes;
96
7
}
97
98
694
void IDictionary::load_values(const std::vector<ColumnPtr>& values_column) {
99
    // load value column
100
694
    _values_data.resize(values_column.size());
101
1.39k
    for (size_t i = 0; i < values_column.size(); i++) {
102
700
        const DataTypePtr value_type_without_nullable = remove_nullable(_attributes[i].type);
103
700
        ColumnPtr value_column_without_nullable = remove_nullable(values_column[i]);
104
700
        if (_attributes[i].type->is_nullable() != values_column[i]->is_nullable()) {
105
0
            throw doris::Exception(
106
0
                    ErrorCode::INVALID_ARGUMENT,
107
0
                    "Dictionary({}) attribute {} type is : {} , column is : {}  Not supported",
108
0
                    dict_name(), _attributes[i].name, _attributes[i].type->get_name(),
109
0
                    values_column[i]->get_name());
110
0
        }
111
700
        bool valid =
112
700
                IDictionary::cast_type(value_type_without_nullable.get(), [&](const auto& type) {
113
700
                    using ValueRealDataType = std::decay_t<decltype(type)>;
114
700
                    auto& att = _values_data[i];
115
700
                    auto init_column_with_type = [&](auto& column_with_type) {
116
700
                        column_with_type.column = value_column_without_nullable;
117
                        // if original value is nullable, the null_map must be not null
118
700
                        if (values_column[i]->is_nullable()) {
119
3
                            column_with_type.null_map =
120
3
                                    assert_cast<const ColumnNullable*, TypeCheckOnRelease::DISABLE>(
121
3
                                            values_column[i].get())
122
3
                                            ->get_null_map_column_ptr();
123
697
                        } else {
124
697
                            column_with_type.null_map = nullptr;
125
697
                        }
126
700
                        att = column_with_type;
127
700
                    };
Unexecuted instantiation: dictionary.cpp:_ZZZN5doris10vectorized11IDictionary11load_valuesERKSt6vectorINS_3COWINS0_7IColumnEE13immutable_ptrIS4_EESaIS7_EEENK3$_0clINS0_14DataTypeNumberIhEEEEDaRKT_ENKUlRSG_E_clINS1_14ColumnWithTypeINS1_20DictDataTypeString64EEEEEDaSJ_
dictionary.cpp:_ZZZN5doris10vectorized11IDictionary11load_valuesERKSt6vectorINS_3COWINS0_7IColumnEE13immutable_ptrIS4_EESaIS7_EEENK3$_0clINS0_14DataTypeNumberIhEEEEDaRKT_ENKUlRSG_E_clINS1_14ColumnWithTypeISF_EEEEDaSJ_
Line
Count
Source
115
52
                    auto init_column_with_type = [&](auto& column_with_type) {
116
52
                        column_with_type.column = value_column_without_nullable;
117
                        // if original value is nullable, the null_map must be not null
118
52
                        if (values_column[i]->is_nullable()) {
119
0
                            column_with_type.null_map =
120
0
                                    assert_cast<const ColumnNullable*, TypeCheckOnRelease::DISABLE>(
121
0
                                            values_column[i].get())
122
0
                                            ->get_null_map_column_ptr();
123
52
                        } else {
124
52
                            column_with_type.null_map = nullptr;
125
52
                        }
126
52
                        att = column_with_type;
127
52
                    };
Unexecuted instantiation: dictionary.cpp:_ZZZN5doris10vectorized11IDictionary11load_valuesERKSt6vectorINS_3COWINS0_7IColumnEE13immutable_ptrIS4_EESaIS7_EEENK3$_0clINS0_14DataTypeNumberIaEEEEDaRKT_ENKUlRSG_E_clINS1_14ColumnWithTypeINS1_20DictDataTypeString64EEEEEDaSJ_
dictionary.cpp:_ZZZN5doris10vectorized11IDictionary11load_valuesERKSt6vectorINS_3COWINS0_7IColumnEE13immutable_ptrIS4_EESaIS7_EEENK3$_0clINS0_14DataTypeNumberIaEEEEDaRKT_ENKUlRSG_E_clINS1_14ColumnWithTypeISF_EEEEDaSJ_
Line
Count
Source
115
52
                    auto init_column_with_type = [&](auto& column_with_type) {
116
52
                        column_with_type.column = value_column_without_nullable;
117
                        // if original value is nullable, the null_map must be not null
118
52
                        if (values_column[i]->is_nullable()) {
119
0
                            column_with_type.null_map =
120
0
                                    assert_cast<const ColumnNullable*, TypeCheckOnRelease::DISABLE>(
121
0
                                            values_column[i].get())
122
0
                                            ->get_null_map_column_ptr();
123
52
                        } else {
124
52
                            column_with_type.null_map = nullptr;
125
52
                        }
126
52
                        att = column_with_type;
127
52
                    };
Unexecuted instantiation: dictionary.cpp:_ZZZN5doris10vectorized11IDictionary11load_valuesERKSt6vectorINS_3COWINS0_7IColumnEE13immutable_ptrIS4_EESaIS7_EEENK3$_0clINS0_14DataTypeNumberIsEEEEDaRKT_ENKUlRSG_E_clINS1_14ColumnWithTypeINS1_20DictDataTypeString64EEEEEDaSJ_
dictionary.cpp:_ZZZN5doris10vectorized11IDictionary11load_valuesERKSt6vectorINS_3COWINS0_7IColumnEE13immutable_ptrIS4_EESaIS7_EEENK3$_0clINS0_14DataTypeNumberIsEEEEDaRKT_ENKUlRSG_E_clINS1_14ColumnWithTypeISF_EEEEDaSJ_
Line
Count
Source
115
52
                    auto init_column_with_type = [&](auto& column_with_type) {
116
52
                        column_with_type.column = value_column_without_nullable;
117
                        // if original value is nullable, the null_map must be not null
118
52
                        if (values_column[i]->is_nullable()) {
119
0
                            column_with_type.null_map =
120
0
                                    assert_cast<const ColumnNullable*, TypeCheckOnRelease::DISABLE>(
121
0
                                            values_column[i].get())
122
0
                                            ->get_null_map_column_ptr();
123
52
                        } else {
124
52
                            column_with_type.null_map = nullptr;
125
52
                        }
126
52
                        att = column_with_type;
127
52
                    };
Unexecuted instantiation: dictionary.cpp:_ZZZN5doris10vectorized11IDictionary11load_valuesERKSt6vectorINS_3COWINS0_7IColumnEE13immutable_ptrIS4_EESaIS7_EEENK3$_0clINS0_14DataTypeNumberIiEEEEDaRKT_ENKUlRSG_E_clINS1_14ColumnWithTypeINS1_20DictDataTypeString64EEEEEDaSJ_
dictionary.cpp:_ZZZN5doris10vectorized11IDictionary11load_valuesERKSt6vectorINS_3COWINS0_7IColumnEE13immutable_ptrIS4_EESaIS7_EEENK3$_0clINS0_14DataTypeNumberIiEEEEDaRKT_ENKUlRSG_E_clINS1_14ColumnWithTypeISF_EEEEDaSJ_
Line
Count
Source
115
65
                    auto init_column_with_type = [&](auto& column_with_type) {
116
65
                        column_with_type.column = value_column_without_nullable;
117
                        // if original value is nullable, the null_map must be not null
118
65
                        if (values_column[i]->is_nullable()) {
119
3
                            column_with_type.null_map =
120
3
                                    assert_cast<const ColumnNullable*, TypeCheckOnRelease::DISABLE>(
121
3
                                            values_column[i].get())
122
3
                                            ->get_null_map_column_ptr();
123
62
                        } else {
124
62
                            column_with_type.null_map = nullptr;
125
62
                        }
126
65
                        att = column_with_type;
127
65
                    };
Unexecuted instantiation: dictionary.cpp:_ZZZN5doris10vectorized11IDictionary11load_valuesERKSt6vectorINS_3COWINS0_7IColumnEE13immutable_ptrIS4_EESaIS7_EEENK3$_0clINS0_14DataTypeNumberIlEEEEDaRKT_ENKUlRSG_E_clINS1_14ColumnWithTypeINS1_20DictDataTypeString64EEEEEDaSJ_
dictionary.cpp:_ZZZN5doris10vectorized11IDictionary11load_valuesERKSt6vectorINS_3COWINS0_7IColumnEE13immutable_ptrIS4_EESaIS7_EEENK3$_0clINS0_14DataTypeNumberIlEEEEDaRKT_ENKUlRSG_E_clINS1_14ColumnWithTypeISF_EEEEDaSJ_
Line
Count
Source
115
58
                    auto init_column_with_type = [&](auto& column_with_type) {
116
58
                        column_with_type.column = value_column_without_nullable;
117
                        // if original value is nullable, the null_map must be not null
118
58
                        if (values_column[i]->is_nullable()) {
119
0
                            column_with_type.null_map =
120
0
                                    assert_cast<const ColumnNullable*, TypeCheckOnRelease::DISABLE>(
121
0
                                            values_column[i].get())
122
0
                                            ->get_null_map_column_ptr();
123
58
                        } else {
124
58
                            column_with_type.null_map = nullptr;
125
58
                        }
126
58
                        att = column_with_type;
127
58
                    };
Unexecuted instantiation: dictionary.cpp:_ZZZN5doris10vectorized11IDictionary11load_valuesERKSt6vectorINS_3COWINS0_7IColumnEE13immutable_ptrIS4_EESaIS7_EEENK3$_0clINS0_14DataTypeNumberInEEEEDaRKT_ENKUlRSG_E_clINS1_14ColumnWithTypeINS1_20DictDataTypeString64EEEEEDaSJ_
dictionary.cpp:_ZZZN5doris10vectorized11IDictionary11load_valuesERKSt6vectorINS_3COWINS0_7IColumnEE13immutable_ptrIS4_EESaIS7_EEENK3$_0clINS0_14DataTypeNumberInEEEEDaRKT_ENKUlRSG_E_clINS1_14ColumnWithTypeISF_EEEEDaSJ_
Line
Count
Source
115
52
                    auto init_column_with_type = [&](auto& column_with_type) {
116
52
                        column_with_type.column = value_column_without_nullable;
117
                        // if original value is nullable, the null_map must be not null
118
52
                        if (values_column[i]->is_nullable()) {
119
0
                            column_with_type.null_map =
120
0
                                    assert_cast<const ColumnNullable*, TypeCheckOnRelease::DISABLE>(
121
0
                                            values_column[i].get())
122
0
                                            ->get_null_map_column_ptr();
123
52
                        } else {
124
52
                            column_with_type.null_map = nullptr;
125
52
                        }
126
52
                        att = column_with_type;
127
52
                    };
Unexecuted instantiation: dictionary.cpp:_ZZZN5doris10vectorized11IDictionary11load_valuesERKSt6vectorINS_3COWINS0_7IColumnEE13immutable_ptrIS4_EESaIS7_EEENK3$_0clINS0_14DataTypeNumberIfEEEEDaRKT_ENKUlRSG_E_clINS1_14ColumnWithTypeINS1_20DictDataTypeString64EEEEEDaSJ_
dictionary.cpp:_ZZZN5doris10vectorized11IDictionary11load_valuesERKSt6vectorINS_3COWINS0_7IColumnEE13immutable_ptrIS4_EESaIS7_EEENK3$_0clINS0_14DataTypeNumberIfEEEEDaRKT_ENKUlRSG_E_clINS1_14ColumnWithTypeISF_EEEEDaSJ_
Line
Count
Source
115
53
                    auto init_column_with_type = [&](auto& column_with_type) {
116
53
                        column_with_type.column = value_column_without_nullable;
117
                        // if original value is nullable, the null_map must be not null
118
53
                        if (values_column[i]->is_nullable()) {
119
0
                            column_with_type.null_map =
120
0
                                    assert_cast<const ColumnNullable*, TypeCheckOnRelease::DISABLE>(
121
0
                                            values_column[i].get())
122
0
                                            ->get_null_map_column_ptr();
123
53
                        } else {
124
53
                            column_with_type.null_map = nullptr;
125
53
                        }
126
53
                        att = column_with_type;
127
53
                    };
Unexecuted instantiation: dictionary.cpp:_ZZZN5doris10vectorized11IDictionary11load_valuesERKSt6vectorINS_3COWINS0_7IColumnEE13immutable_ptrIS4_EESaIS7_EEENK3$_0clINS0_14DataTypeNumberIdEEEEDaRKT_ENKUlRSG_E_clINS1_14ColumnWithTypeINS1_20DictDataTypeString64EEEEEDaSJ_
dictionary.cpp:_ZZZN5doris10vectorized11IDictionary11load_valuesERKSt6vectorINS_3COWINS0_7IColumnEE13immutable_ptrIS4_EESaIS7_EEENK3$_0clINS0_14DataTypeNumberIdEEEEDaRKT_ENKUlRSG_E_clINS1_14ColumnWithTypeISF_EEEEDaSJ_
Line
Count
Source
115
52
                    auto init_column_with_type = [&](auto& column_with_type) {
116
52
                        column_with_type.column = value_column_without_nullable;
117
                        // if original value is nullable, the null_map must be not null
118
52
                        if (values_column[i]->is_nullable()) {
119
0
                            column_with_type.null_map =
120
0
                                    assert_cast<const ColumnNullable*, TypeCheckOnRelease::DISABLE>(
121
0
                                            values_column[i].get())
122
0
                                            ->get_null_map_column_ptr();
123
52
                        } else {
124
52
                            column_with_type.null_map = nullptr;
125
52
                        }
126
52
                        att = column_with_type;
127
52
                    };
Unexecuted instantiation: dictionary.cpp:_ZZZN5doris10vectorized11IDictionary11load_valuesERKSt6vectorINS_3COWINS0_7IColumnEE13immutable_ptrIS4_EESaIS7_EEENK3$_0clINS0_12DataTypeIPv4EEEDaRKT_ENKUlRSF_E_clINS1_14ColumnWithTypeINS1_20DictDataTypeString64EEEEEDaSI_
dictionary.cpp:_ZZZN5doris10vectorized11IDictionary11load_valuesERKSt6vectorINS_3COWINS0_7IColumnEE13immutable_ptrIS4_EESaIS7_EEENK3$_0clINS0_12DataTypeIPv4EEEDaRKT_ENKUlRSF_E_clINS1_14ColumnWithTypeISE_EEEEDaSI_
Line
Count
Source
115
52
                    auto init_column_with_type = [&](auto& column_with_type) {
116
52
                        column_with_type.column = value_column_without_nullable;
117
                        // if original value is nullable, the null_map must be not null
118
52
                        if (values_column[i]->is_nullable()) {
119
0
                            column_with_type.null_map =
120
0
                                    assert_cast<const ColumnNullable*, TypeCheckOnRelease::DISABLE>(
121
0
                                            values_column[i].get())
122
0
                                            ->get_null_map_column_ptr();
123
52
                        } else {
124
52
                            column_with_type.null_map = nullptr;
125
52
                        }
126
52
                        att = column_with_type;
127
52
                    };
Unexecuted instantiation: dictionary.cpp:_ZZZN5doris10vectorized11IDictionary11load_valuesERKSt6vectorINS_3COWINS0_7IColumnEE13immutable_ptrIS4_EESaIS7_EEENK3$_0clINS0_12DataTypeIPv6EEEDaRKT_ENKUlRSF_E_clINS1_14ColumnWithTypeINS1_20DictDataTypeString64EEEEEDaSI_
dictionary.cpp:_ZZZN5doris10vectorized11IDictionary11load_valuesERKSt6vectorINS_3COWINS0_7IColumnEE13immutable_ptrIS4_EESaIS7_EEENK3$_0clINS0_12DataTypeIPv6EEEDaRKT_ENKUlRSF_E_clINS1_14ColumnWithTypeISE_EEEEDaSI_
Line
Count
Source
115
52
                    auto init_column_with_type = [&](auto& column_with_type) {
116
52
                        column_with_type.column = value_column_without_nullable;
117
                        // if original value is nullable, the null_map must be not null
118
52
                        if (values_column[i]->is_nullable()) {
119
0
                            column_with_type.null_map =
120
0
                                    assert_cast<const ColumnNullable*, TypeCheckOnRelease::DISABLE>(
121
0
                                            values_column[i].get())
122
0
                                            ->get_null_map_column_ptr();
123
52
                        } else {
124
52
                            column_with_type.null_map = nullptr;
125
52
                        }
126
52
                        att = column_with_type;
127
52
                    };
dictionary.cpp:_ZZZN5doris10vectorized11IDictionary11load_valuesERKSt6vectorINS_3COWINS0_7IColumnEE13immutable_ptrIS4_EESaIS7_EEENK3$_0clINS0_14DataTypeStringEEEDaRKT_ENKUlRSF_E_clINS1_14ColumnWithTypeINS1_20DictDataTypeString64EEEEEDaSI_
Line
Count
Source
115
27
                    auto init_column_with_type = [&](auto& column_with_type) {
116
27
                        column_with_type.column = value_column_without_nullable;
117
                        // if original value is nullable, the null_map must be not null
118
27
                        if (values_column[i]->is_nullable()) {
119
0
                            column_with_type.null_map =
120
0
                                    assert_cast<const ColumnNullable*, TypeCheckOnRelease::DISABLE>(
121
0
                                            values_column[i].get())
122
0
                                            ->get_null_map_column_ptr();
123
27
                        } else {
124
27
                            column_with_type.null_map = nullptr;
125
27
                        }
126
27
                        att = column_with_type;
127
27
                    };
dictionary.cpp:_ZZZN5doris10vectorized11IDictionary11load_valuesERKSt6vectorINS_3COWINS0_7IColumnEE13immutable_ptrIS4_EESaIS7_EEENK3$_0clINS0_14DataTypeStringEEEDaRKT_ENKUlRSF_E_clINS1_14ColumnWithTypeISE_EEEEDaSI_
Line
Count
Source
115
29
                    auto init_column_with_type = [&](auto& column_with_type) {
116
29
                        column_with_type.column = value_column_without_nullable;
117
                        // if original value is nullable, the null_map must be not null
118
29
                        if (values_column[i]->is_nullable()) {
119
0
                            column_with_type.null_map =
120
0
                                    assert_cast<const ColumnNullable*, TypeCheckOnRelease::DISABLE>(
121
0
                                            values_column[i].get())
122
0
                                            ->get_null_map_column_ptr();
123
29
                        } else {
124
29
                            column_with_type.null_map = nullptr;
125
29
                        }
126
29
                        att = column_with_type;
127
29
                    };
Unexecuted instantiation: dictionary.cpp:_ZZZN5doris10vectorized11IDictionary11load_valuesERKSt6vectorINS_3COWINS0_7IColumnEE13immutable_ptrIS4_EESaIS7_EEENK3$_0clINS0_14DataTypeDateV2EEEDaRKT_ENKUlRSF_E_clINS1_14ColumnWithTypeINS1_20DictDataTypeString64EEEEEDaSI_
dictionary.cpp:_ZZZN5doris10vectorized11IDictionary11load_valuesERKSt6vectorINS_3COWINS0_7IColumnEE13immutable_ptrIS4_EESaIS7_EEENK3$_0clINS0_14DataTypeDateV2EEEDaRKT_ENKUlRSF_E_clINS1_14ColumnWithTypeISE_EEEEDaSI_
Line
Count
Source
115
52
                    auto init_column_with_type = [&](auto& column_with_type) {
116
52
                        column_with_type.column = value_column_without_nullable;
117
                        // if original value is nullable, the null_map must be not null
118
52
                        if (values_column[i]->is_nullable()) {
119
0
                            column_with_type.null_map =
120
0
                                    assert_cast<const ColumnNullable*, TypeCheckOnRelease::DISABLE>(
121
0
                                            values_column[i].get())
122
0
                                            ->get_null_map_column_ptr();
123
52
                        } else {
124
52
                            column_with_type.null_map = nullptr;
125
52
                        }
126
52
                        att = column_with_type;
127
52
                    };
Unexecuted instantiation: dictionary.cpp:_ZZZN5doris10vectorized11IDictionary11load_valuesERKSt6vectorINS_3COWINS0_7IColumnEE13immutable_ptrIS4_EESaIS7_EEENK3$_0clINS0_18DataTypeDateTimeV2EEEDaRKT_ENKUlRSF_E_clINS1_14ColumnWithTypeINS1_20DictDataTypeString64EEEEEDaSI_
dictionary.cpp:_ZZZN5doris10vectorized11IDictionary11load_valuesERKSt6vectorINS_3COWINS0_7IColumnEE13immutable_ptrIS4_EESaIS7_EEENK3$_0clINS0_18DataTypeDateTimeV2EEEDaRKT_ENKUlRSF_E_clINS1_14ColumnWithTypeISE_EEEEDaSI_
Line
Count
Source
115
52
                    auto init_column_with_type = [&](auto& column_with_type) {
116
52
                        column_with_type.column = value_column_without_nullable;
117
                        // if original value is nullable, the null_map must be not null
118
52
                        if (values_column[i]->is_nullable()) {
119
0
                            column_with_type.null_map =
120
0
                                    assert_cast<const ColumnNullable*, TypeCheckOnRelease::DISABLE>(
121
0
                                            values_column[i].get())
122
0
                                            ->get_null_map_column_ptr();
123
52
                        } else {
124
52
                            column_with_type.null_map = nullptr;
125
52
                        }
126
52
                        att = column_with_type;
127
52
                    };
Unexecuted instantiation: dictionary.cpp:_ZZZN5doris10vectorized11IDictionary11load_valuesERKSt6vectorINS_3COWINS0_7IColumnEE13immutable_ptrIS4_EESaIS7_EEENK3$_0clINS0_15DataTypeDecimalINS0_7DecimalIiEEEEEEDaRKT_ENKUlRSI_E_clINS1_14ColumnWithTypeINS1_20DictDataTypeString64EEEEEDaSL_
Unexecuted instantiation: dictionary.cpp:_ZZZN5doris10vectorized11IDictionary11load_valuesERKSt6vectorINS_3COWINS0_7IColumnEE13immutable_ptrIS4_EESaIS7_EEENK3$_0clINS0_15DataTypeDecimalINS0_7DecimalIiEEEEEEDaRKT_ENKUlRSI_E_clINS1_14ColumnWithTypeISH_EEEEDaSL_
Unexecuted instantiation: dictionary.cpp:_ZZZN5doris10vectorized11IDictionary11load_valuesERKSt6vectorINS_3COWINS0_7IColumnEE13immutable_ptrIS4_EESaIS7_EEENK3$_0clINS0_15DataTypeDecimalINS0_7DecimalIlEEEEEEDaRKT_ENKUlRSI_E_clINS1_14ColumnWithTypeINS1_20DictDataTypeString64EEEEEDaSL_
Unexecuted instantiation: dictionary.cpp:_ZZZN5doris10vectorized11IDictionary11load_valuesERKSt6vectorINS_3COWINS0_7IColumnEE13immutable_ptrIS4_EESaIS7_EEENK3$_0clINS0_15DataTypeDecimalINS0_7DecimalIlEEEEEEDaRKT_ENKUlRSI_E_clINS1_14ColumnWithTypeISH_EEEEDaSL_
Unexecuted instantiation: dictionary.cpp:_ZZZN5doris10vectorized11IDictionary11load_valuesERKSt6vectorINS_3COWINS0_7IColumnEE13immutable_ptrIS4_EESaIS7_EEENK3$_0clINS0_15DataTypeDecimalINS0_12Decimal128V3EEEEEDaRKT_ENKUlRSH_E_clINS1_14ColumnWithTypeINS1_20DictDataTypeString64EEEEEDaSK_
Unexecuted instantiation: dictionary.cpp:_ZZZN5doris10vectorized11IDictionary11load_valuesERKSt6vectorINS_3COWINS0_7IColumnEE13immutable_ptrIS4_EESaIS7_EEENK3$_0clINS0_15DataTypeDecimalINS0_12Decimal128V3EEEEEDaRKT_ENKUlRSH_E_clINS1_14ColumnWithTypeISG_EEEEDaSK_
Unexecuted instantiation: dictionary.cpp:_ZZZN5doris10vectorized11IDictionary11load_valuesERKSt6vectorINS_3COWINS0_7IColumnEE13immutable_ptrIS4_EESaIS7_EEENK3$_0clINS0_15DataTypeDecimalINS0_7DecimalIN4wide7integerILm256EiEEEEEEEEDaRKT_ENKUlRSL_E_clINS1_14ColumnWithTypeINS1_20DictDataTypeString64EEEEEDaSO_
Unexecuted instantiation: dictionary.cpp:_ZZZN5doris10vectorized11IDictionary11load_valuesERKSt6vectorINS_3COWINS0_7IColumnEE13immutable_ptrIS4_EESaIS7_EEENK3$_0clINS0_15DataTypeDecimalINS0_7DecimalIN4wide7integerILm256EiEEEEEEEEDaRKT_ENKUlRSL_E_clINS1_14ColumnWithTypeISK_EEEEDaSO_
128
129
700
                    if (value_column_without_nullable->is_column_string64()) {
130
27
                        ColumnWithType<DictDataTypeString64> column_with_type;
131
27
                        init_column_with_type(column_with_type);
132
673
                    } else {
133
673
                        ColumnWithType<ValueRealDataType> column_with_type;
134
673
                        init_column_with_type(column_with_type);
135
673
                    }
136
700
                    return true;
137
700
                });
dictionary.cpp:_ZZN5doris10vectorized11IDictionary11load_valuesERKSt6vectorINS_3COWINS0_7IColumnEE13immutable_ptrIS4_EESaIS7_EEENK3$_0clINS0_14DataTypeNumberIhEEEEDaRKT_
Line
Count
Source
112
52
                IDictionary::cast_type(value_type_without_nullable.get(), [&](const auto& type) {
113
52
                    using ValueRealDataType = std::decay_t<decltype(type)>;
114
52
                    auto& att = _values_data[i];
115
52
                    auto init_column_with_type = [&](auto& column_with_type) {
116
52
                        column_with_type.column = value_column_without_nullable;
117
                        // if original value is nullable, the null_map must be not null
118
52
                        if (values_column[i]->is_nullable()) {
119
52
                            column_with_type.null_map =
120
52
                                    assert_cast<const ColumnNullable*, TypeCheckOnRelease::DISABLE>(
121
52
                                            values_column[i].get())
122
52
                                            ->get_null_map_column_ptr();
123
52
                        } else {
124
52
                            column_with_type.null_map = nullptr;
125
52
                        }
126
52
                        att = column_with_type;
127
52
                    };
128
129
52
                    if (value_column_without_nullable->is_column_string64()) {
130
0
                        ColumnWithType<DictDataTypeString64> column_with_type;
131
0
                        init_column_with_type(column_with_type);
132
52
                    } else {
133
52
                        ColumnWithType<ValueRealDataType> column_with_type;
134
52
                        init_column_with_type(column_with_type);
135
52
                    }
136
52
                    return true;
137
52
                });
dictionary.cpp:_ZZN5doris10vectorized11IDictionary11load_valuesERKSt6vectorINS_3COWINS0_7IColumnEE13immutable_ptrIS4_EESaIS7_EEENK3$_0clINS0_14DataTypeNumberIaEEEEDaRKT_
Line
Count
Source
112
52
                IDictionary::cast_type(value_type_without_nullable.get(), [&](const auto& type) {
113
52
                    using ValueRealDataType = std::decay_t<decltype(type)>;
114
52
                    auto& att = _values_data[i];
115
52
                    auto init_column_with_type = [&](auto& column_with_type) {
116
52
                        column_with_type.column = value_column_without_nullable;
117
                        // if original value is nullable, the null_map must be not null
118
52
                        if (values_column[i]->is_nullable()) {
119
52
                            column_with_type.null_map =
120
52
                                    assert_cast<const ColumnNullable*, TypeCheckOnRelease::DISABLE>(
121
52
                                            values_column[i].get())
122
52
                                            ->get_null_map_column_ptr();
123
52
                        } else {
124
52
                            column_with_type.null_map = nullptr;
125
52
                        }
126
52
                        att = column_with_type;
127
52
                    };
128
129
52
                    if (value_column_without_nullable->is_column_string64()) {
130
0
                        ColumnWithType<DictDataTypeString64> column_with_type;
131
0
                        init_column_with_type(column_with_type);
132
52
                    } else {
133
52
                        ColumnWithType<ValueRealDataType> column_with_type;
134
52
                        init_column_with_type(column_with_type);
135
52
                    }
136
52
                    return true;
137
52
                });
dictionary.cpp:_ZZN5doris10vectorized11IDictionary11load_valuesERKSt6vectorINS_3COWINS0_7IColumnEE13immutable_ptrIS4_EESaIS7_EEENK3$_0clINS0_14DataTypeNumberIsEEEEDaRKT_
Line
Count
Source
112
52
                IDictionary::cast_type(value_type_without_nullable.get(), [&](const auto& type) {
113
52
                    using ValueRealDataType = std::decay_t<decltype(type)>;
114
52
                    auto& att = _values_data[i];
115
52
                    auto init_column_with_type = [&](auto& column_with_type) {
116
52
                        column_with_type.column = value_column_without_nullable;
117
                        // if original value is nullable, the null_map must be not null
118
52
                        if (values_column[i]->is_nullable()) {
119
52
                            column_with_type.null_map =
120
52
                                    assert_cast<const ColumnNullable*, TypeCheckOnRelease::DISABLE>(
121
52
                                            values_column[i].get())
122
52
                                            ->get_null_map_column_ptr();
123
52
                        } else {
124
52
                            column_with_type.null_map = nullptr;
125
52
                        }
126
52
                        att = column_with_type;
127
52
                    };
128
129
52
                    if (value_column_without_nullable->is_column_string64()) {
130
0
                        ColumnWithType<DictDataTypeString64> column_with_type;
131
0
                        init_column_with_type(column_with_type);
132
52
                    } else {
133
52
                        ColumnWithType<ValueRealDataType> column_with_type;
134
52
                        init_column_with_type(column_with_type);
135
52
                    }
136
52
                    return true;
137
52
                });
dictionary.cpp:_ZZN5doris10vectorized11IDictionary11load_valuesERKSt6vectorINS_3COWINS0_7IColumnEE13immutable_ptrIS4_EESaIS7_EEENK3$_0clINS0_14DataTypeNumberIiEEEEDaRKT_
Line
Count
Source
112
65
                IDictionary::cast_type(value_type_without_nullable.get(), [&](const auto& type) {
113
65
                    using ValueRealDataType = std::decay_t<decltype(type)>;
114
65
                    auto& att = _values_data[i];
115
65
                    auto init_column_with_type = [&](auto& column_with_type) {
116
65
                        column_with_type.column = value_column_without_nullable;
117
                        // if original value is nullable, the null_map must be not null
118
65
                        if (values_column[i]->is_nullable()) {
119
65
                            column_with_type.null_map =
120
65
                                    assert_cast<const ColumnNullable*, TypeCheckOnRelease::DISABLE>(
121
65
                                            values_column[i].get())
122
65
                                            ->get_null_map_column_ptr();
123
65
                        } else {
124
65
                            column_with_type.null_map = nullptr;
125
65
                        }
126
65
                        att = column_with_type;
127
65
                    };
128
129
65
                    if (value_column_without_nullable->is_column_string64()) {
130
0
                        ColumnWithType<DictDataTypeString64> column_with_type;
131
0
                        init_column_with_type(column_with_type);
132
65
                    } else {
133
65
                        ColumnWithType<ValueRealDataType> column_with_type;
134
65
                        init_column_with_type(column_with_type);
135
65
                    }
136
65
                    return true;
137
65
                });
dictionary.cpp:_ZZN5doris10vectorized11IDictionary11load_valuesERKSt6vectorINS_3COWINS0_7IColumnEE13immutable_ptrIS4_EESaIS7_EEENK3$_0clINS0_14DataTypeNumberIlEEEEDaRKT_
Line
Count
Source
112
58
                IDictionary::cast_type(value_type_without_nullable.get(), [&](const auto& type) {
113
58
                    using ValueRealDataType = std::decay_t<decltype(type)>;
114
58
                    auto& att = _values_data[i];
115
58
                    auto init_column_with_type = [&](auto& column_with_type) {
116
58
                        column_with_type.column = value_column_without_nullable;
117
                        // if original value is nullable, the null_map must be not null
118
58
                        if (values_column[i]->is_nullable()) {
119
58
                            column_with_type.null_map =
120
58
                                    assert_cast<const ColumnNullable*, TypeCheckOnRelease::DISABLE>(
121
58
                                            values_column[i].get())
122
58
                                            ->get_null_map_column_ptr();
123
58
                        } else {
124
58
                            column_with_type.null_map = nullptr;
125
58
                        }
126
58
                        att = column_with_type;
127
58
                    };
128
129
58
                    if (value_column_without_nullable->is_column_string64()) {
130
0
                        ColumnWithType<DictDataTypeString64> column_with_type;
131
0
                        init_column_with_type(column_with_type);
132
58
                    } else {
133
58
                        ColumnWithType<ValueRealDataType> column_with_type;
134
58
                        init_column_with_type(column_with_type);
135
58
                    }
136
58
                    return true;
137
58
                });
dictionary.cpp:_ZZN5doris10vectorized11IDictionary11load_valuesERKSt6vectorINS_3COWINS0_7IColumnEE13immutable_ptrIS4_EESaIS7_EEENK3$_0clINS0_14DataTypeNumberInEEEEDaRKT_
Line
Count
Source
112
52
                IDictionary::cast_type(value_type_without_nullable.get(), [&](const auto& type) {
113
52
                    using ValueRealDataType = std::decay_t<decltype(type)>;
114
52
                    auto& att = _values_data[i];
115
52
                    auto init_column_with_type = [&](auto& column_with_type) {
116
52
                        column_with_type.column = value_column_without_nullable;
117
                        // if original value is nullable, the null_map must be not null
118
52
                        if (values_column[i]->is_nullable()) {
119
52
                            column_with_type.null_map =
120
52
                                    assert_cast<const ColumnNullable*, TypeCheckOnRelease::DISABLE>(
121
52
                                            values_column[i].get())
122
52
                                            ->get_null_map_column_ptr();
123
52
                        } else {
124
52
                            column_with_type.null_map = nullptr;
125
52
                        }
126
52
                        att = column_with_type;
127
52
                    };
128
129
52
                    if (value_column_without_nullable->is_column_string64()) {
130
0
                        ColumnWithType<DictDataTypeString64> column_with_type;
131
0
                        init_column_with_type(column_with_type);
132
52
                    } else {
133
52
                        ColumnWithType<ValueRealDataType> column_with_type;
134
52
                        init_column_with_type(column_with_type);
135
52
                    }
136
52
                    return true;
137
52
                });
dictionary.cpp:_ZZN5doris10vectorized11IDictionary11load_valuesERKSt6vectorINS_3COWINS0_7IColumnEE13immutable_ptrIS4_EESaIS7_EEENK3$_0clINS0_14DataTypeNumberIfEEEEDaRKT_
Line
Count
Source
112
53
                IDictionary::cast_type(value_type_without_nullable.get(), [&](const auto& type) {
113
53
                    using ValueRealDataType = std::decay_t<decltype(type)>;
114
53
                    auto& att = _values_data[i];
115
53
                    auto init_column_with_type = [&](auto& column_with_type) {
116
53
                        column_with_type.column = value_column_without_nullable;
117
                        // if original value is nullable, the null_map must be not null
118
53
                        if (values_column[i]->is_nullable()) {
119
53
                            column_with_type.null_map =
120
53
                                    assert_cast<const ColumnNullable*, TypeCheckOnRelease::DISABLE>(
121
53
                                            values_column[i].get())
122
53
                                            ->get_null_map_column_ptr();
123
53
                        } else {
124
53
                            column_with_type.null_map = nullptr;
125
53
                        }
126
53
                        att = column_with_type;
127
53
                    };
128
129
53
                    if (value_column_without_nullable->is_column_string64()) {
130
0
                        ColumnWithType<DictDataTypeString64> column_with_type;
131
0
                        init_column_with_type(column_with_type);
132
53
                    } else {
133
53
                        ColumnWithType<ValueRealDataType> column_with_type;
134
53
                        init_column_with_type(column_with_type);
135
53
                    }
136
53
                    return true;
137
53
                });
dictionary.cpp:_ZZN5doris10vectorized11IDictionary11load_valuesERKSt6vectorINS_3COWINS0_7IColumnEE13immutable_ptrIS4_EESaIS7_EEENK3$_0clINS0_14DataTypeNumberIdEEEEDaRKT_
Line
Count
Source
112
52
                IDictionary::cast_type(value_type_without_nullable.get(), [&](const auto& type) {
113
52
                    using ValueRealDataType = std::decay_t<decltype(type)>;
114
52
                    auto& att = _values_data[i];
115
52
                    auto init_column_with_type = [&](auto& column_with_type) {
116
52
                        column_with_type.column = value_column_without_nullable;
117
                        // if original value is nullable, the null_map must be not null
118
52
                        if (values_column[i]->is_nullable()) {
119
52
                            column_with_type.null_map =
120
52
                                    assert_cast<const ColumnNullable*, TypeCheckOnRelease::DISABLE>(
121
52
                                            values_column[i].get())
122
52
                                            ->get_null_map_column_ptr();
123
52
                        } else {
124
52
                            column_with_type.null_map = nullptr;
125
52
                        }
126
52
                        att = column_with_type;
127
52
                    };
128
129
52
                    if (value_column_without_nullable->is_column_string64()) {
130
0
                        ColumnWithType<DictDataTypeString64> column_with_type;
131
0
                        init_column_with_type(column_with_type);
132
52
                    } else {
133
52
                        ColumnWithType<ValueRealDataType> column_with_type;
134
52
                        init_column_with_type(column_with_type);
135
52
                    }
136
52
                    return true;
137
52
                });
dictionary.cpp:_ZZN5doris10vectorized11IDictionary11load_valuesERKSt6vectorINS_3COWINS0_7IColumnEE13immutable_ptrIS4_EESaIS7_EEENK3$_0clINS0_12DataTypeIPv4EEEDaRKT_
Line
Count
Source
112
52
                IDictionary::cast_type(value_type_without_nullable.get(), [&](const auto& type) {
113
52
                    using ValueRealDataType = std::decay_t<decltype(type)>;
114
52
                    auto& att = _values_data[i];
115
52
                    auto init_column_with_type = [&](auto& column_with_type) {
116
52
                        column_with_type.column = value_column_without_nullable;
117
                        // if original value is nullable, the null_map must be not null
118
52
                        if (values_column[i]->is_nullable()) {
119
52
                            column_with_type.null_map =
120
52
                                    assert_cast<const ColumnNullable*, TypeCheckOnRelease::DISABLE>(
121
52
                                            values_column[i].get())
122
52
                                            ->get_null_map_column_ptr();
123
52
                        } else {
124
52
                            column_with_type.null_map = nullptr;
125
52
                        }
126
52
                        att = column_with_type;
127
52
                    };
128
129
52
                    if (value_column_without_nullable->is_column_string64()) {
130
0
                        ColumnWithType<DictDataTypeString64> column_with_type;
131
0
                        init_column_with_type(column_with_type);
132
52
                    } else {
133
52
                        ColumnWithType<ValueRealDataType> column_with_type;
134
52
                        init_column_with_type(column_with_type);
135
52
                    }
136
52
                    return true;
137
52
                });
dictionary.cpp:_ZZN5doris10vectorized11IDictionary11load_valuesERKSt6vectorINS_3COWINS0_7IColumnEE13immutable_ptrIS4_EESaIS7_EEENK3$_0clINS0_12DataTypeIPv6EEEDaRKT_
Line
Count
Source
112
52
                IDictionary::cast_type(value_type_without_nullable.get(), [&](const auto& type) {
113
52
                    using ValueRealDataType = std::decay_t<decltype(type)>;
114
52
                    auto& att = _values_data[i];
115
52
                    auto init_column_with_type = [&](auto& column_with_type) {
116
52
                        column_with_type.column = value_column_without_nullable;
117
                        // if original value is nullable, the null_map must be not null
118
52
                        if (values_column[i]->is_nullable()) {
119
52
                            column_with_type.null_map =
120
52
                                    assert_cast<const ColumnNullable*, TypeCheckOnRelease::DISABLE>(
121
52
                                            values_column[i].get())
122
52
                                            ->get_null_map_column_ptr();
123
52
                        } else {
124
52
                            column_with_type.null_map = nullptr;
125
52
                        }
126
52
                        att = column_with_type;
127
52
                    };
128
129
52
                    if (value_column_without_nullable->is_column_string64()) {
130
0
                        ColumnWithType<DictDataTypeString64> column_with_type;
131
0
                        init_column_with_type(column_with_type);
132
52
                    } else {
133
52
                        ColumnWithType<ValueRealDataType> column_with_type;
134
52
                        init_column_with_type(column_with_type);
135
52
                    }
136
52
                    return true;
137
52
                });
dictionary.cpp:_ZZN5doris10vectorized11IDictionary11load_valuesERKSt6vectorINS_3COWINS0_7IColumnEE13immutable_ptrIS4_EESaIS7_EEENK3$_0clINS0_14DataTypeStringEEEDaRKT_
Line
Count
Source
112
56
                IDictionary::cast_type(value_type_without_nullable.get(), [&](const auto& type) {
113
56
                    using ValueRealDataType = std::decay_t<decltype(type)>;
114
56
                    auto& att = _values_data[i];
115
56
                    auto init_column_with_type = [&](auto& column_with_type) {
116
56
                        column_with_type.column = value_column_without_nullable;
117
                        // if original value is nullable, the null_map must be not null
118
56
                        if (values_column[i]->is_nullable()) {
119
56
                            column_with_type.null_map =
120
56
                                    assert_cast<const ColumnNullable*, TypeCheckOnRelease::DISABLE>(
121
56
                                            values_column[i].get())
122
56
                                            ->get_null_map_column_ptr();
123
56
                        } else {
124
56
                            column_with_type.null_map = nullptr;
125
56
                        }
126
56
                        att = column_with_type;
127
56
                    };
128
129
56
                    if (value_column_without_nullable->is_column_string64()) {
130
27
                        ColumnWithType<DictDataTypeString64> column_with_type;
131
27
                        init_column_with_type(column_with_type);
132
29
                    } else {
133
29
                        ColumnWithType<ValueRealDataType> column_with_type;
134
29
                        init_column_with_type(column_with_type);
135
29
                    }
136
56
                    return true;
137
56
                });
dictionary.cpp:_ZZN5doris10vectorized11IDictionary11load_valuesERKSt6vectorINS_3COWINS0_7IColumnEE13immutable_ptrIS4_EESaIS7_EEENK3$_0clINS0_14DataTypeDateV2EEEDaRKT_
Line
Count
Source
112
52
                IDictionary::cast_type(value_type_without_nullable.get(), [&](const auto& type) {
113
52
                    using ValueRealDataType = std::decay_t<decltype(type)>;
114
52
                    auto& att = _values_data[i];
115
52
                    auto init_column_with_type = [&](auto& column_with_type) {
116
52
                        column_with_type.column = value_column_without_nullable;
117
                        // if original value is nullable, the null_map must be not null
118
52
                        if (values_column[i]->is_nullable()) {
119
52
                            column_with_type.null_map =
120
52
                                    assert_cast<const ColumnNullable*, TypeCheckOnRelease::DISABLE>(
121
52
                                            values_column[i].get())
122
52
                                            ->get_null_map_column_ptr();
123
52
                        } else {
124
52
                            column_with_type.null_map = nullptr;
125
52
                        }
126
52
                        att = column_with_type;
127
52
                    };
128
129
52
                    if (value_column_without_nullable->is_column_string64()) {
130
0
                        ColumnWithType<DictDataTypeString64> column_with_type;
131
0
                        init_column_with_type(column_with_type);
132
52
                    } else {
133
52
                        ColumnWithType<ValueRealDataType> column_with_type;
134
52
                        init_column_with_type(column_with_type);
135
52
                    }
136
52
                    return true;
137
52
                });
dictionary.cpp:_ZZN5doris10vectorized11IDictionary11load_valuesERKSt6vectorINS_3COWINS0_7IColumnEE13immutable_ptrIS4_EESaIS7_EEENK3$_0clINS0_18DataTypeDateTimeV2EEEDaRKT_
Line
Count
Source
112
52
                IDictionary::cast_type(value_type_without_nullable.get(), [&](const auto& type) {
113
52
                    using ValueRealDataType = std::decay_t<decltype(type)>;
114
52
                    auto& att = _values_data[i];
115
52
                    auto init_column_with_type = [&](auto& column_with_type) {
116
52
                        column_with_type.column = value_column_without_nullable;
117
                        // if original value is nullable, the null_map must be not null
118
52
                        if (values_column[i]->is_nullable()) {
119
52
                            column_with_type.null_map =
120
52
                                    assert_cast<const ColumnNullable*, TypeCheckOnRelease::DISABLE>(
121
52
                                            values_column[i].get())
122
52
                                            ->get_null_map_column_ptr();
123
52
                        } else {
124
52
                            column_with_type.null_map = nullptr;
125
52
                        }
126
52
                        att = column_with_type;
127
52
                    };
128
129
52
                    if (value_column_without_nullable->is_column_string64()) {
130
0
                        ColumnWithType<DictDataTypeString64> column_with_type;
131
0
                        init_column_with_type(column_with_type);
132
52
                    } else {
133
52
                        ColumnWithType<ValueRealDataType> column_with_type;
134
52
                        init_column_with_type(column_with_type);
135
52
                    }
136
52
                    return true;
137
52
                });
Unexecuted instantiation: dictionary.cpp:_ZZN5doris10vectorized11IDictionary11load_valuesERKSt6vectorINS_3COWINS0_7IColumnEE13immutable_ptrIS4_EESaIS7_EEENK3$_0clINS0_15DataTypeDecimalINS0_7DecimalIiEEEEEEDaRKT_
Unexecuted instantiation: dictionary.cpp:_ZZN5doris10vectorized11IDictionary11load_valuesERKSt6vectorINS_3COWINS0_7IColumnEE13immutable_ptrIS4_EESaIS7_EEENK3$_0clINS0_15DataTypeDecimalINS0_7DecimalIlEEEEEEDaRKT_
Unexecuted instantiation: dictionary.cpp:_ZZN5doris10vectorized11IDictionary11load_valuesERKSt6vectorINS_3COWINS0_7IColumnEE13immutable_ptrIS4_EESaIS7_EEENK3$_0clINS0_15DataTypeDecimalINS0_12Decimal128V3EEEEEDaRKT_
Unexecuted instantiation: dictionary.cpp:_ZZN5doris10vectorized11IDictionary11load_valuesERKSt6vectorINS_3COWINS0_7IColumnEE13immutable_ptrIS4_EESaIS7_EEENK3$_0clINS0_15DataTypeDecimalINS0_7DecimalIN4wide7integerILm256EiEEEEEEEEDaRKT_
138
700
        if (!valid) {
139
0
            throw doris::Exception(
140
0
                    ErrorCode::INVALID_ARGUMENT,
141
0
                    "Dictionary({}) attribute {} type is : {} , column is : {}  Not supported",
142
0
                    dict_name(), _attributes[i].name, _attributes[i].type->get_name(),
143
0
                    values_column[i]->get_name());
144
0
        }
145
700
    }
146
694
}
147
148
} // namespace doris::vectorized