Skip to content

Commit ba0b8b7

Browse files
committed
add comment about optimization in the else if/else logic
1 parent 163977e commit ba0b8b7

File tree

1 file changed

+5
-0
lines changed
  • rust/experimental/query_engine/engine-columnar/src

1 file changed

+5
-0
lines changed

rust/experimental/query_engine/engine-columnar/src/engine.rs

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -286,6 +286,9 @@ impl OtapBatchEngine {
286286

287287
// build the plan for everything not selected by the if statement
288288
let root_plan = exec_ctx.root_batch_plan()?;
289+
290+
// TODO -- if the filter condition didn't have joins, we could probably
291+
// actually just use a `not(filter_cond)` here and avoid the join
289292
let mut next_branch_plan = root_plan.join(
290293
filtered_plan.build()?,
291294
JoinType::LeftAnti,
@@ -317,6 +320,8 @@ impl OtapBatchEngine {
317320

318321
// the next branch will receive everything that didn't match the previous branches
319322
// and also didn't match this branch's conditions
323+
// TODO -- if the filter condition didn't have joins, we could probably
324+
// actually just use a `not(filter_cond)` here and avoid the join
320325
next_branch_plan = next_branch_plan.join(
321326
filtered_plan.build()?,
322327
JoinType::LeftAnti,

0 commit comments

Comments
 (0)