Returns all `Expr`s in the schema, except the `Column`s in the `columns_to_skip`
(
schema: &DFSchema,
columns_to_skip: &HashSet<Column>,
)
| 386 | |
| 387 | /// Returns all `Expr`s in the schema, except the `Column`s in the `columns_to_skip` |
| 388 | fn get_exprs_except_skipped( |
| 389 | schema: &DFSchema, |
| 390 | columns_to_skip: &HashSet<Column>, |
| 391 | ) -> Vec<Expr> { |
| 392 | if columns_to_skip.is_empty() { |
| 393 | schema.iter().map(Expr::from).collect::<Vec<Expr>>() |
| 394 | } else { |
| 395 | schema |
| 396 | .columns() |
| 397 | .iter() |
| 398 | .filter_map(|c| { |
| 399 | if !columns_to_skip.contains(c) { |
| 400 | Some(Expr::Column(c.clone())) |
| 401 | } else { |
| 402 | None |
| 403 | } |
| 404 | }) |
| 405 | .collect::<Vec<Expr>>() |
| 406 | } |
| 407 | } |
| 408 | |
| 409 | /// When a JOIN has a USING clause, the join columns appear in the output |
| 410 | /// schema once per side (for inner/outer joins) or once total (for semi/anti |