fn plan_contains_other_subqueries(plan: &LogicalPlan, cte_name: &str) -> boolExpand description
Returns true if the plan subtree contains any subqueries that are not the
CTE reference itself. This treats any non-CTE LogicalPlan::SubqueryAlias
node (including aliased relations) as a blocker, along with expression-level
subqueries like scalar, EXISTS, or IN. These cases prevent projection
pushdown for now because we cannot safely reason about their column usage.