alamb commented on issue #2181:
URL: 
https://github.com/apache/arrow-datafusion/issues/2181#issuecomment-1096587791

   There are two kinds of subqueries
   * Uncorrelated (aka subqueries that appear in the from clause that don't 
have references to the outer query)
   * Correlated (subqueries that appear in the from clause or IN / NOT IN /etc 
and that refer to the outer query)
   
   For correlated queries that that refer to the outer query using `=` 
predicates they can be transformed into SEMI-JOIN / ANTI-JOIN typically
   
   Correlated queries that use something other than `=` (non equijoins) 
eventually have to be run once per each row in the outer query and would likely 
be expressed as a `LogicalPlan` in an `Expr`. 
   
   that being said, I think we can get very far in DataFusion (maybe forever) 
by handling only uncorrelated and equi-join correlated subqueries and avoid 
LogicalPlan in Expr


-- 
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]

Reply via email to