(
ecx: &ExprContext,
query: &Query<Aug>,
)
| 4659 | } |
| 4660 | |
| 4661 | fn plan_array_subquery( |
| 4662 | ecx: &ExprContext, |
| 4663 | query: &Query<Aug>, |
| 4664 | ) -> Result<CoercibleScalarExpr, PlanError> { |
| 4665 | plan_vector_like_subquery( |
| 4666 | ecx, |
| 4667 | query, |
| 4668 | |elem_type| { |
| 4669 | matches!( |
| 4670 | elem_type, |
| 4671 | SqlScalarType::Char { .. } |
| 4672 | | SqlScalarType::Array { .. } |
| 4673 | | SqlScalarType::List { .. } |
| 4674 | | SqlScalarType::Map { .. } |
| 4675 | ) |
| 4676 | }, |
| 4677 | |elem_type| ArrayCreate { elem_type }.into(), |
| 4678 | |order_by| AggregateFunc::ArrayConcat { order_by }, |
| 4679 | expr_func::ArrayArrayConcat.into(), |
| 4680 | |elem_type| { |
| 4681 | HirScalarExpr::literal( |
| 4682 | Datum::empty_array(), |
| 4683 | SqlScalarType::Array(Box::new(elem_type)), |
| 4684 | ) |
| 4685 | }, |
| 4686 | "[]", |
| 4687 | ) |
| 4688 | } |
| 4689 | |
| 4690 | /// Generic function used to plan both array subqueries and list subqueries |
| 4691 | fn plan_vector_like_subquery<F1, F2, F3, F4>( |
no test coverage detected