You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@orc.apache.org by GitBox <gi...@apache.org> on 2022/03/03 08:05:06 UTC
[GitHub] [orc] PengleiShi opened a new issue #1053: Predicate pushdown does not work
PengleiShi opened a new issue #1053:
URL: https://github.com/apache/orc/issues/1053
Hi, I have a problem, my test data is tpc-ds 1g, spark 3.2, orc version 1.6.11,
test sql `select count(1) from call_center_orc where cc_call_center_sk > 100;`
`cc_call_center_sk` is the first column in `call_center_orc`, and predicate pushdown is effectual

but when i test `select count(1) from call_center_orc where cc_company > 100;`
`cc_company` is not the first column, predicate pushdown does not work

And I debug the code, I found the problem is `SchemaEvolution.ppdSafeConversion`,

in my case, `result.size` is 2, but in `pickRowGroups`

the `columnIx` is the column index in orc meta, which is 19 for `cc_company`, this causes orc will not evaluate pushdown filters with row group stats, and can not skip the row group.
--
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: dev-unsubscribe@orc.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
[GitHub] [orc] guiyanakuang commented on issue #1053: Predicate pushdown does not work
Posted by GitBox <gi...@apache.org>.
guiyanakuang commented on issue #1053:
URL: https://github.com/apache/orc/issues/1053#issuecomment-1057848763
I'll do some investigation later
--
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: dev-unsubscribe@orc.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
[GitHub] [orc] dongjoon-hyun commented on issue #1053: Predicate pushdown does not work
Posted by GitBox <gi...@apache.org>.
dongjoon-hyun commented on issue #1053:
URL: https://github.com/apache/orc/issues/1053#issuecomment-1057842190
Thank you for reporting, @PengleiShi . Could you make a PR for that?
--
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: dev-unsubscribe@orc.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
[GitHub] [orc] guiyanakuang commented on issue #1053: Predicate pushdown does not work
Posted by GitBox <gi...@apache.org>.
guiyanakuang commented on issue #1053:
URL: https://github.com/apache/orc/issues/1053#issuecomment-1058098766
I reviewed SchemaEvolution.java and determined that it was a bug.
I think maybe we can initialize a map to store `fileTypeId` to `readTypeId` via `readerFileTypes`.
```java
Map<Integer, Integer> typeIdsMap = new HashMap<>();
for (int i = 0; i < this.readerFileTypes.length; i++) {
this.typeIdsMap.put(readerFileTypes[i].getId(), i);
}
public boolean isPPDSafeConversion(final int colId) {
if (hasConversion()) {
Integer readTypeId = typeIdsMap.get(colId);
return readTypeId != null &&
ppdSafeConversion[readTypeId];
}
// when there is no schema evolution PPD is safe
return true;
}
```
Welcome @PengleiShi for making this pr. 🍻
--
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: dev-unsubscribe@orc.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
[GitHub] [orc] PengleiShi commented on issue #1053: Predicate pushdown does not work
Posted by GitBox <gi...@apache.org>.
PengleiShi commented on issue #1053:
URL: https://github.com/apache/orc/issues/1053#issuecomment-1057856397
> Thank you for reporting, @PengleiShi . Could you make a PR for that?
I'am willing to try.
--
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: dev-unsubscribe@orc.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
[GitHub] [orc] dongjoon-hyun commented on issue #1053: Predicate pushdown does not work
Posted by GitBox <gi...@apache.org>.
dongjoon-hyun commented on issue #1053:
URL: https://github.com/apache/orc/issues/1053#issuecomment-1057843610
cc @pgaref , @williamhyun , @guiyanakuang
--
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: dev-unsubscribe@orc.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
[GitHub] [orc] guiyanakuang commented on issue #1053: Predicate pushdown does not work
Posted by GitBox <gi...@apache.org>.
guiyanakuang commented on issue #1053:
URL: https://github.com/apache/orc/issues/1053#issuecomment-1058794755
Yes, we need the PR prefix to be associated with Jira.
--
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: dev-unsubscribe@orc.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
[GitHub] [orc] dongjoon-hyun closed issue #1053: Predicate pushdown does not work
Posted by GitBox <gi...@apache.org>.
dongjoon-hyun closed issue #1053:
URL: https://github.com/apache/orc/issues/1053
--
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: dev-unsubscribe@orc.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
[GitHub] [orc] PengleiShi commented on issue #1053: Predicate pushdown does not work
Posted by GitBox <gi...@apache.org>.
PengleiShi commented on issue #1053:
URL: https://github.com/apache/orc/issues/1053#issuecomment-1058791782
@guiyanakuang Thanks, I'll do it. And should i open a new issue in Jira?
--
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: dev-unsubscribe@orc.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
[GitHub] [orc] dongjoon-hyun commented on issue #1053: Predicate pushdown does not work
Posted by GitBox <gi...@apache.org>.
dongjoon-hyun commented on issue #1053:
URL: https://github.com/apache/orc/issues/1053#issuecomment-1062205799
This is resolved via https://github.com/apache/orc/pull/1055
--
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: dev-unsubscribe@orc.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org