row group skipping for is [not] null queries
This commit is contained in:
parent
95748a5192
commit
110e3e3668
|
@ -44,11 +44,16 @@ bool ParquetCursor::currentRowGroupSatisfiesFilter() {
|
||||||
if(column == -1) {
|
if(column == -1) {
|
||||||
rv = currentRowGroupSatisfiesRowIdFilter(constraints[i]);
|
rv = currentRowGroupSatisfiesRowIdFilter(constraints[i]);
|
||||||
} else {
|
} else {
|
||||||
// printf("column = %d\n", column);
|
std::unique_ptr<parquet::ColumnChunkMetaData> md = rowGroupMetadata->ColumnChunk(column);
|
||||||
// std::unique_ptr<parquet::ColumnChunkMetaData> md = rowGroupMetadata->ColumnChunk(column);
|
if(!md->is_stats_set()) {
|
||||||
|
continue;
|
||||||
|
}
|
||||||
|
std::shared_ptr<parquet::RowGroupStatistics> stats = md->statistics();
|
||||||
|
|
||||||
if(op == IsNull) {
|
if(op == IsNull) {
|
||||||
|
rv = stats->null_count() > 0;
|
||||||
} else if(op == IsNotNull) {
|
} else if(op == IsNotNull) {
|
||||||
|
rv = stats->num_values() > 0;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -39,7 +39,7 @@ main() {
|
||||||
exit 1
|
exit 1
|
||||||
fi
|
fi
|
||||||
|
|
||||||
if [ "$(cat testcases.txt | wc -l)" == "1" ]; then
|
if [ ! -v NO_DEBUG ] && [ "$(cat testcases.txt | wc -l)" == "1" ]; then
|
||||||
set -x
|
set -x
|
||||||
gdb -ex run --args "$root"/sqlite/sqlite3 -init testcase-cmds.txt
|
gdb -ex run --args "$root"/sqlite/sqlite3 -init testcase-cmds.txt
|
||||||
else
|
else
|
||||||
|
|
Loading…
Reference in New Issue