Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
11 changes: 10 additions & 1 deletion be/src/olap/rowset/segment_v2/segment_iterator.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -2614,7 +2614,16 @@ void SegmentIterator::_calculate_pred_in_remaining_conjunct_root(

auto node_type = expr->node_type();
if (node_type == TExprNodeType::SLOT_REF) {
_column_predicate_info->column_name = expr->expr_name();
if (_column_predicate_info->column_name.empty()) {
_column_predicate_info->column_name = expr->expr_name();
} else {
// If column name already exists, create a new ColumnPredicateInfo
// if expr is columnA > columnB, then column name will exist, in this situation, we need to add it to _column_pred_in_remaining_vconjunct
auto new_column_pred_info = std::make_shared<ColumnPredicateInfo>();
new_column_pred_info->column_name = expr->expr_name();
_column_pred_in_remaining_vconjunct[new_column_pred_info->column_name].push_back(
*new_column_pred_info);
}
} else if (_is_literal_node(node_type)) {
auto v_literal_expr = static_cast<const doris::vectorized::VLiteral*>(expr.get());
_column_predicate_info->query_value = v_literal_expr->value();
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -136,3 +136,77 @@ j 2 k
k 2 j
u 8 d

-- !select_no_need_1 --
1 -5960927335705409832 5 3
1 -10 -10 9
1 -10 -4 -4
1 -10 1 2
1 -10 3 6
1 -10 4 -4
1 -10 7 3
1 -10 9 1
2 -4 -10 -10
1 -4 -10 3
1 -4 3 3
1 0 -4 5
1 0 2 9
1 0 5 1
1 0 5 3
1 1 -10 5
1 1 0 -4
1 1 4 3
1 1 7 -10
1 1 9 -4
1 2 8 -4
1 3 -10 8
1 3 -4 9
1 3 3 -4
1 5 -10 -10
1 5 -4 1
1 5 1 8
1 6 -10 -4
1 7 -10 2
1 7 1 6
1 7 2 8
1 7 3 -4
1 7 8 -10
1 8 -10 -10
1 8 -10 3
1 8 -10 8
2 8 -10 9
1 8 -4 5
1 8 -4 8
1 8 4 -4
1 8 4 3
1 8 5 -10
1 8 5 2
1 8 8 1
1 9 -4 2
1 9 6 1
1 25 2 -10
1 26 2 -10

-- !select_no_need_2 --
1.2

-- !select_no_need_3 --
2023-12-09 -5522213112273370561 2023-12-16
2023-12-09 -4155137914128855235 2023-12-12
2023-12-10 \N 2023-12-19
2023-12-10 8625368487501035525 2023-12-17
2023-12-11 4714785027515578912 2023-12-10
2023-12-15 \N 2024-01-09
2023-12-15 -559291350287121968 2023-12-16
2023-12-16 -4473441684795462099 2023-12-15
2023-12-18 \N 2025-06-18
2023-12-18 419678391523752890 2026-01-18
2023-12-20 6152093303748835632 2023-12-17
2024-01-09 \N 2025-06-18
2024-01-17 2371697304713448324 2024-01-09
2025-02-17 -4599200440035458276 2024-01-19
2025-06-18 -1196385874478092971 2023-12-17
2025-06-18 -750688512374970345 2024-01-17
2025-06-18 7670879000600913113 2023-12-09
2026-01-18 9039465042666792521 2023-12-09
2026-02-18 -3974342907695018910 2024-01-09

Loading