You are viewing a plain text version of this content. The canonical link for it is here.
Posted to github@arrow.apache.org by GitBox <gi...@apache.org> on 2022/12/30 03:44:25 UTC
[GitHub] [arrow-datafusion] jackwener commented on a diff in pull request #4753: Take the top level `schema` into account when creating `UnionExec`
jackwener commented on code in PR #4753:
URL: https://github.com/apache/arrow-datafusion/pull/4753#discussion_r1059230136
##########
datafusion/core/tests/sql/union.rs:
##########
@@ -80,6 +80,23 @@ async fn union_all_with_aggregate() -> Result<()> {
Ok(())
}
+#[tokio::test]
+async fn union_all_with_count() -> Result<()> {
+ let ctx = SessionContext::new();
+ execute_to_batches(&ctx, "CREATE table t as SELECT 1 as a").await;
+ let sql = "SELECT COUNT(*) FROM (SELECT a from t UNION ALL SELECT a from t)";
Review Comment:
> BTW, I'm not sure if it was a bug, but the `PushDownProjection` doesn't push down the empty projection to the child plans of `Union` in this example. Maybe @jackwener knows more about it.
we need an issue to track this problem, I think there are some different ways of dealing with this problem.
--
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: github-unsubscribe@arrow.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org