Skip to main content

Module planner

Module planner 

Source
Expand description

Query planning module for the Alopex SQL dialect.

This module provides:

  • PlannerError: Error types for planning phase
  • ResolvedType: Normalized type information for type checking
  • TypedExpr: Type-checked expressions with resolved types
  • LogicalPlan: Logical query plan representation
  • NameResolver: Table and column reference resolution
  • TypeChecker: Expression type inference and validation
  • Planner: Main entry point for converting AST to LogicalPlan

Re-exports§

pub use aggregate_expr::AggregateExpr;
pub use aggregate_expr::AggregateFunction;
pub use knn_optimizer::KnnPattern;
pub use knn_optimizer::SortDirection;
pub use knn_optimizer::detect_knn_pattern;
pub use logical_plan::JoinType;
pub use logical_plan::LogicalPlan;
pub use name_resolver::NameResolver;
pub use name_resolver::ResolvedColumn;
pub use type_checker::ScopedTable;
pub use type_checker::TypeChecker;
pub use typed_expr::ProjectedColumn;
pub use typed_expr::Projection;
pub use typed_expr::SortExpr;
pub use typed_expr::TypedAssignment;
pub use typed_expr::TypedExpr;
pub use typed_expr::TypedExprKind;
pub use types::ResolvedType;

Modules§

aggregate_expr
knn_optimizer
logical_plan
Logical plan representation for query execution.
name_resolver
Name resolution for SQL queries.
type_checker
Type checking module for the Alopex SQL dialect.
typed_expr
Type-checked expression types for the planner.
types
Type definitions for the Alopex SQL planner.

Structs§

PlannedStatement
Planning output used by server-side routing analysis.
Planner
The SQL query planner.
PlanningDiagnostic
SQL planning diagnostic attachment point for routing layers.
RoutingInput
SQL-owned input for routing decision composition.
TableReference
A table reference visible at the SQL planning boundary.
TableReferenceExtractor
Extracts physical table references from SQL-owned planner structures.

Enums§

PlannerError
Planner errors for the Alopex SQL dialect.
PlanningDiagnosticSeverity
Severity for planning diagnostics.
TableReferenceAccess
Access class for a table reference.
TableReferenceSource
Where a table reference was extracted from.

Functions§

plan_sql_for_routing
Parse and plan SQL without executing it, returning SQL-owned routing input.
plan_statement_for_routing
Plan a parsed statement without executing it, returning SQL-owned routing input.