Convert a logical expression to a physical expression (without any simplification, etc)
(expr: &Expr, schema: &Schema)
| 588 | |
| 589 | /// Convert a logical expression to a physical expression (without any simplification, etc) |
| 590 | pub fn logical2physical(expr: &Expr, schema: &Schema) -> Arc<dyn PhysicalExpr> { |
| 591 | // TODO this makes a deep copy of the Schema. Should take SchemaRef instead and avoid deep copy |
| 592 | let df_schema = schema.clone().to_dfschema().unwrap(); |
| 593 | let execution_props = ExecutionProps::new(); |
| 594 | create_physical_expr(expr, &df_schema, &execution_props).unwrap() |
| 595 | } |
| 596 | |
| 597 | #[cfg(test)] |
| 598 | mod tests { |
searching dependent graphs…