Skip to content

Commit

Permalink
Query condition should use fragment's array schema (#2698) (#2743)
Browse files Browse the repository at this point in the history
With schema evolution each fragment now carries a reference to its array
schema. This is the schema that should be used when looping over the
tile to apply query condition. This ensures that the schema matches the
tile.

Co-authored-by: Seth Shelnutt <seth@tiledb.io>
  • Loading branch information
github-actions[bot] and Shelnutt2 committed Dec 15, 2021
1 parent db55fa8 commit 5ba6edf
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion tiledb/sm/query/dense_reader.cc
Expand Up @@ -554,7 +554,7 @@ Status DenseReader::apply_query_condition(
&start,
&end)) {
RETURN_NOT_OK(condition_.apply_dense<DimType>(
array_schema_,
fragment_metadata_[frag_domains[i].first]->array_schema(),
it->second.result_tile(frag_domains[i].first),
start,
end - start + 1,
Expand Down
2 changes: 1 addition & 1 deletion tiledb/sm/query/sparse_index_reader_base.cc
Expand Up @@ -553,7 +553,7 @@ Status SparseIndexReaderBase::apply_query_condition(

// Compute the result of the query condition for this tile.
RETURN_NOT_OK(condition_.apply_sparse<BitmapType>(
array_schema_,
fragment_metadata_[rt->frag_idx()]->array_schema(),
&*rt,
rt->bitmap_.data(),
&rt->bitmap_result_num_));
Expand Down

0 comments on commit 5ba6edf

Please sign in to comment.