Skip to content

Commit

Permalink
add info log
Browse files Browse the repository at this point in the history
  • Loading branch information
JackTan25 committed Jan 13, 2024
1 parent 2b99973 commit 10879f5
Show file tree
Hide file tree
Showing 4 changed files with 14 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -403,7 +403,7 @@ impl HashJoinProbeState {
let new_matched_count = old_mactehd_counts + 1;
if old_mactehd_counts > 0 {
return Err(ErrorCode::UnresolvableConflict(
"multi rows from source match one and the same row in the target_table multi times",
"multi rows from source match one and the same row in the target_table multi times in probe phase",
));
}
loop {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -133,6 +133,10 @@ impl TransformHashJoinProbe {
if item.0.is_empty() {
let prefix = item.1;
let (segment_idx, block_idx) = split_prefix(prefix);
info!(
"matched whole block: segment_idx: {}, block_idx: {}",
segment_idx, block_idx
);
let data_block = DataBlock::empty_with_meta(Box::new(BlockMetaIndex {
segment_idx: segment_idx as usize,
block_idx: block_idx as usize,
Expand All @@ -156,6 +160,10 @@ impl TransformHashJoinProbe {
)?;
assert!(!data_block.is_empty());
let (segment_idx, block_idx) = split_prefix(prefix);
info!(
"matched partial block: segment_idx: {}, block_idx: {}",
segment_idx, block_idx
);
let data_block = data_block.add_meta(Some(Box::new(BlockMetaIndex {
segment_idx: segment_idx as usize,
block_idx: block_idx as usize,
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -144,6 +144,10 @@ impl MatchedAggregator {
.meta_indexes
.insert((meta_index.segment_idx, meta_index.block_idx))
{
info!(
"duplicated block: segment_idx: {}, block_idx: {}",
meta_index.segment_idx, meta_index.block_idx
);
return Err(ErrorCode::Internal(
"merge into get duplicated block for target build unmodified optimization",
));
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -286,7 +286,7 @@ target_table: default.default.target_build_optimization
query TT
merge into target_build_optimization as t1 using source_optimization as t2 on t1.a > t2.a and t1.b = t2.b when matched then update * when not matched then insert *;
----
12 0
10 0

query TTT
select * from target_build_optimization order by a,b,c;
Expand Down

0 comments on commit 10879f5

Please sign in to comment.