crm26 commented on PR #21363:
URL: https://github.com/apache/datafusion/pull/21363#issuecomment-4201754197

   Thanks for the thorough review, @neilconway! Addressed all three points in 
the latest push (commit 12a12bcd1):
   
   1. **Optimization: prefix** — Added to the alias preservation comment to 
make it clear it's not required for correctness.
   
   2. **Per-expression early bail-out** — Refactored the loop to call 
`has_subquery(&rewritten)` immediately after each rewrite. Now bails out on 
first failure instead of processing all expressions then checking at the end. 
Semantics are still all-or-nothing (same as ScalarSubqueryToJoin).
   
   3. **Mixed decorrelatable + non-decorrelatable test** — Added 
`projection_mixed_decorrelatable_and_non_bails_out`. Listed the decorrelatable 
`case_ok` first in the projection so it would rewrite successfully before 
`case_bad` triggers the bail-out — this specifically exercises the 
partial-rewrite-then-discard path to ensure `case_ok` doesn't leak a partial 
rewrite.
   
   Validation: 59 decorrelate tests pass (was 58), full optimizer suite (665 + 
26 + 5) passes, fmt + clippy -D warnings clean, subquery.slt passes.


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]


---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to