Skip to content

Commit 4806b77

Browse files
committed
add better descriptions of logical operator fields
1 parent 06b0141 commit 4806b77

File tree

3 files changed

+8
-0
lines changed

3 files changed

+8
-0
lines changed

optd-core/src/operator/relational/logical/filter.rs

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -8,5 +8,8 @@ pub struct Filter<Relation, Scalar> {
88
/// The input relation.
99
pub child: Relation,
1010
/// The filter expression denoting the predicate condition for this filter operation.
11+
///
12+
/// For example, a filter predicate could be `column_a > 42`, or it could be something like
13+
/// `column_b < 100 AND column_c > 1000`.
1114
pub predicate: Scalar,
1215
}

optd-core/src/operator/relational/logical/join.rs

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -13,5 +13,7 @@ pub struct Join<Relation, Scalar> {
1313
/// The right input relation.
1414
pub right: Relation,
1515
/// The join expression denoting the join condition that links the two input relations.
16+
///
17+
/// For example, a join operation could have a condition on `t1.id = t2.id` (an equijoin).
1618
pub condition: Scalar,
1719
}

optd-core/src/operator/relational/logical/scan.rs

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -9,5 +9,8 @@ pub struct Scan<Scalar> {
99
/// TODO(alexis) Mocked for now.
1010
pub table_name: String,
1111
/// An optional filter expression for predicate pushdown into scan operators.
12+
///
13+
/// For example, a `Filter(Scan(A), column_a < 42)` can be converted into a predicate pushdown
14+
/// `Scan(A, column < 42)` to prevent having to materialize many tuples.
1215
pub predicate: Option<Scalar>,
1316
}

0 commit comments

Comments
 (0)