pub enum LogicalPlan {
Show 21 variants AnonymousScan { function: Arc<dyn AnonymousScan + 'static>, schema: Arc<Schema>, predicate: Option<Expr>, options: AnonymousScanOptions, }, Selection { input: Box<LogicalPlan, Global>, predicate: Expr, }, Cache { input: Box<LogicalPlan, Global>, id: usize, count: usize, }, CsvScan { path: PathBuf, schema: Arc<Schema>, options: CsvParserOptions, predicate: Option<Expr>, }, ParquetScan { path: PathBuf, schema: Arc<Schema>, predicate: Option<Expr>, options: ParquetOptions, }, IpcScan { path: PathBuf, schema: Arc<Schema>, options: IpcScanOptionsInner, predicate: Option<Expr>, }, DataFrameScan { df: Arc<DataFrame>, schema: Arc<Schema>, output_schema: Option<Arc<Schema>>, projection: Option<Arc<Vec<String, Global>>>, selection: Option<Expr>, }, LocalProjection { expr: Vec<Expr, Global>, input: Box<LogicalPlan, Global>, schema: Arc<Schema>, }, Projection { expr: Vec<Expr, Global>, input: Box<LogicalPlan, Global>, schema: Arc<Schema>, }, Aggregate { input: Box<LogicalPlan, Global>, keys: Arc<Vec<Expr, Global>>, aggs: Vec<Expr, Global>, schema: Arc<Schema>, apply: Option<Arc<dyn DataFrameUdf + 'static>>, maintain_order: bool, options: GroupbyOptions, }, Join { input_left: Box<LogicalPlan, Global>, input_right: Box<LogicalPlan, Global>, schema: Arc<Schema>, left_on: Vec<Expr, Global>, right_on: Vec<Expr, Global>, options: JoinOptions, }, HStack { input: Box<LogicalPlan, Global>, exprs: Vec<Expr, Global>, schema: Arc<Schema>, }, Distinct { input: Box<LogicalPlan, Global>, options: DistinctOptions, }, Sort { input: Box<LogicalPlan, Global>, by_column: Vec<Expr, Global>, args: SortArguments, }, Explode { input: Box<LogicalPlan, Global>, columns: Vec<String, Global>, schema: Arc<Schema>, }, Slice { input: Box<LogicalPlan, Global>, offset: i64, len: u32, }, Melt { input: Box<LogicalPlan, Global>, args: Arc<MeltArgs>, schema: Arc<Schema>, }, MapFunction { input: Box<LogicalPlan, Global>, function: FunctionNode, }, Union { inputs: Vec<LogicalPlan, Global>, options: UnionOptions, }, Error { input: Box<LogicalPlan, Global>, err: Arc<Mutex<Option<PolarsError>>>, }, ExtContext { input: Box<LogicalPlan, Global>, contexts: Vec<LogicalPlan, Global>, schema: Arc<Schema>, },
}

Variants

AnonymousScan

Fields

function: Arc<dyn AnonymousScan + 'static>
schema: Arc<Schema>
predicate: Option<Expr>

Selection

Fields

predicate: Expr

Filter on a boolean mask

Cache

Fields

id: usize
count: usize

Cache the input at this point in the LP

CsvScan

Fields

path: PathBuf
schema: Arc<Schema>
options: CsvParserOptions
predicate: Option<Expr>

Filters at the scan level

Scan a CSV file

ParquetScan

Fields

path: PathBuf
schema: Arc<Schema>
predicate: Option<Expr>
options: ParquetOptions

Scan a Parquet file

IpcScan

Fields

path: PathBuf
schema: Arc<Schema>
options: IpcScanOptionsInner
predicate: Option<Expr>

DataFrameScan

Fields

schema: Arc<Schema>
output_schema: Option<Arc<Schema>>
projection: Option<Arc<Vec<String, Global>>>
selection: Option<Expr>

In memory DataFrame

LocalProjection

Fields

expr: Vec<Expr, Global>
schema: Arc<Schema>

Projection

Fields

expr: Vec<Expr, Global>
schema: Arc<Schema>

Column selection

Aggregate

Fields

keys: Arc<Vec<Expr, Global>>
aggs: Vec<Expr, Global>
schema: Arc<Schema>
apply: Option<Arc<dyn DataFrameUdf + 'static>>
maintain_order: bool
options: GroupbyOptions

Groupby aggregation

Join

Fields

input_left: Box<LogicalPlan, Global>
input_right: Box<LogicalPlan, Global>
schema: Arc<Schema>
left_on: Vec<Expr, Global>
right_on: Vec<Expr, Global>
options: JoinOptions

Join operation

HStack

Fields

exprs: Vec<Expr, Global>
schema: Arc<Schema>

Adding columns to the table without a Join

Distinct

Fields

options: DistinctOptions

Remove duplicates from the table

Sort

Fields

by_column: Vec<Expr, Global>
args: SortArguments

Sort the table

Explode

Fields

columns: Vec<String, Global>
schema: Arc<Schema>

An explode operation

Slice

Fields

offset: i64
len: u32

Slice the table

Melt

Fields

args: Arc<MeltArgs>
schema: Arc<Schema>

A Melt operation

MapFunction

Fields

function: FunctionNode

A (User Defined) Function

Union

Fields

options: UnionOptions

Error

Fields

Catches errors and throws them later

ExtContext

Fields

contexts: Vec<LogicalPlan, Global>
schema: Arc<Schema>

This allows expressions to access other tables

Implementations

Arguments

id - (branch, id) Used to make sure that the dot boxes are distinct. branch is an id per join/union branch id is incremented by the depth traversal of the tree.

Trait Implementations

Returns a copy of the value. Read more
Performs copy-assignment from source. Read more
Formats the value using the given formatter. Read more
Returns the “default value” for a type. Read more
Converts to this type from the input type.

Auto Trait Implementations

Blanket Implementations

Gets the TypeId of self. Read more
Immutably borrows from an owned value. Read more
Mutably borrows from an owned value. Read more

Returns the argument unchanged.

Calls U::from(self).

That is, this conversion is whatever the implementation of From<T> for U chooses to do.

The alignment of pointer.
The type for initializers.
Initializes a with the given initializer. Read more
Dereferences the given pointer. Read more
Mutably dereferences the given pointer. Read more
Drops the object pointed to by the given pointer. Read more
The resulting type after obtaining ownership.
Creates owned data from borrowed data, usually by cloning. Read more
Uses borrowed data to replace owned data, usually by cloning. Read more
The type returned in the event of a conversion error.
Performs the conversion.
The type returned in the event of a conversion error.
Performs the conversion.