You are viewing a plain text version of this content. The canonical link for it is here.
Posted to github@arrow.apache.org by "jackwener (via GitHub)" <gi...@apache.org> on 2023/06/09 13:51:38 UTC
[GitHub] [arrow-datafusion] jackwener opened a new issue, #6613: `from_plan` should create projection by using original schema
jackwener opened a new issue, #6613:
URL: https://github.com/apache/arrow-datafusion/issues/6613
### Describe the bug
#5821 is caused by this problem.
In original code, project call `from_plan`, it will keep original schema even if expression are different.
It's wrong! Because different expression will have different schema.
code is wrong
```rust
LogicalPlan::Projection(Projection { schema, .. }) => {
Ok(LogicalPlan::Projection(Projection::try_new_with_schema(
expr.to_vec(),
Arc::new(inputs[0].clone()),
schema. Clone(),
)?))
}
```
should be
```rust
LogicalPlan::Projection(_) => Ok(LogicalPlan::Projection(Projection::try_new(
expr.to_vec(),
Arc::new(inputs[0].clone()),
)?)),
```
### To Reproduce
_No response_
### Expected behavior
_No response_
### Additional context
_No response_
--
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.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
[GitHub] [arrow-datafusion] jackwener commented on issue #6613: `from_plan` should create projection by using original schema
Posted by "jackwener (via GitHub)" <gi...@apache.org>.
jackwener commented on issue #6613:
URL: https://github.com/apache/arrow-datafusion/issues/6613#issuecomment-1584833747
cc @alamb @mslapek
--
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
[GitHub] [arrow-datafusion] jackwener closed issue #6613: `from_plan` shouldn't create projection by using original schema
Posted by "jackwener (via GitHub)" <gi...@apache.org>.
jackwener closed issue #6613: `from_plan` shouldn't create projection by using original schema
URL: https://github.com/apache/arrow-datafusion/issues/6613
--
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
[GitHub] [arrow-datafusion] alamb commented on issue #6613: `from_plan` should create projection by using original schema
Posted by "alamb (via GitHub)" <gi...@apache.org>.
alamb commented on issue #6613:
URL: https://github.com/apache/arrow-datafusion/issues/6613#issuecomment-1584837167
Good catch @jackwener
--
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