Expand description
some utils for helping with batching mode
StructsΒ§
- AddFilter
Rewriter - Find out the
FilterNode corresponding to innermost(deepest)WHEREand add a new filter expr to it - Column
Matcher Rewriter - Optionally add to the final select columns like
update_atif the sink table has such column (which doesnβt necessary need to have exact name just need to be a extra timestamp column) and__ts_placeholder(this column need to have exact this name and be a timestamp) with values likenow()and0 - Find
Group ByFinal Name - Helper to find the innermost group by expr in schema, return None if no group by expr
- Incremental
Aggregate Analysis - Analysis result for an incremental aggregate plan.
- Incremental
Aggregate Merge Column - Describes how one aggregate output field should be merged with the corresponding existing field in the sink table.
- Output
Projection πInfo
EnumsΒ§
FunctionsΒ§
- analyze_
incremental_ aggregate_ plan - build_
left_ πjoin_ merge_ expr - check_
input_ πplan_ shape - collect_
output_ πprojection_ info - df_
plan_ to_ sql - extract_
incremental_ πaggregate - find_
column_ πnames - Recursively find all
Expr::Columnnames inside an expression tree. Only recurses into wrappers that are merge-transparent. Non-transparent wrappers (e.g.,ScalarFunction,Negative,Cast) are intentionally not recursed into since their merge semantics would be incorrect. - find_
group_ πkey_ names - find_
uncovered_ πoutput_ fields - find_
unsupported_ πgroup_ key_ projection_ outputs - gen_
plan_ πwith_ matching_ schema - Generate a plan that matches the schema of the sink table from given sql by alias and adding auto columns
- get_
table_ info_ df_ schema - has_
aggregate π - has_
grouping_ πset - merge_
op_ πfor_ aggregate_ expr - peel_
subquery_ πaliases - qualified_
col π - qualified_
column π - resolve_
aggregate_ πoutput_ field_ name - rewrite_
incremental_ aggregate_ with_ sink_ merge - Rewrites one incremental aggregate delta plan by left-joining it with the existing sink-table state and projecting merged aggregate outputs.
- sql_
to_ df_ plan - Convert sql to datafusion logical plan Also support TQL (but only Eval not Explain or Analyze)
- unqualified_
col π