File tree Expand file tree Collapse file tree 1 file changed +8
-2
lines changed Expand file tree Collapse file tree 1 file changed +8
-2
lines changed Original file line number Diff line number Diff line change @@ -1211,9 +1211,15 @@ InversionNode* Retrieval::makeIndexScanNode(IndexScratch* indexScratch) const
12111211 // This index is never used for IS NULL, thus we can ignore NULLs
12121212 // already at index scan. But this rule doesn't apply to nod_equiv
12131213 // which requires NULLs to be found in the index.
1214- // A second exception is when this index is used for navigation.
1215- if (ignoreNullsOnScan && !(idx->idx_runtime_flags & idx_navigate))
1214+ //
1215+ // dimitr: make sure the check below is never moved outside the IF scope,
1216+ // as this flag must not be set for a full index scan,
1217+ // see also the assertion below
1218+ if (ignoreNullsOnScan)
1219+ {
1220+ fb_assert (indexScratch->lowerCount || indexScratch->upperCount );
12161221 retrieval->irb_generic |= irb_ignore_null_value_key;
1222+ }
12171223
12181224 const auto & lastSegment = segments[count - 1 ];
12191225
You can’t perform that action at this time.
0 commit comments