LiaCastaneda commented on PR #16454:
URL: https://github.com/apache/datafusion/pull/16454#issuecomment-3045022842
> I am sorry I didn't quite follow if this fix is specific to substrait or
if it also fixes some issue that could be hit with a SQL as well? Specifically,
is there any SQL query that would fail prior to this fix but pass after it?
I would say It’s specific to Substrait given that I’ve only observed this
error in Substrait queries, and only under a very narrow set of conditions: the
join key is an expression (different to Column), the join type is `INNER`, and
there are identical column names on both sides of the join. For example the
following join is specified as an inner join in the substrait plan & then a
projection with the right columns is applied on top:
```
SELECT Upper(host) AS host_expr,
Max(total_bytes) AS db_size
FROM db_metrics
WHERE Upper(host) IN (SELECT host_expr
FROM index_sizes)
```
I haven’t been able to reproduce the same error through any other execution
path. In the regular path, this query is likely rewritten as a semi-join, so
the issue doesn’t arise.
--
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]