With Collection Indexer should index leading MISSING entries

Description

indexer service will not index the document when leading index key is MISSING.
Index selection must be made such that when queries can give right results. Otherwise index must not be chosen.
So index to qualify, the leading index key must be part of the predicate or user must explicitly give leadingkey IS NOT MISSING.

Example:

By adding MISSING attribute on leading indexing key and indexer indexes MISSING like below. Any query on the default can use ix2. SLA specific queries can create there own targeted indexes.

CREATE INDEX ix2 ON default(b INCLUDE MISSING);

Affects versions

Fix versions

Environment

None

Release Notes Description

None

Activity

Show:

CB robot October 7, 2022 at 8:56 AM

Build couchbase-server-7.2.0-5000 contains query-ee commit b81fae1 with commit message:
. Leading Index Key MISSING

CB robot October 7, 2022 at 8:56 AM

Build couchbase-server-7.2.0-5000 contains query-ee commit 8249af1 with commit message:
. Add optional ALLOW keyword before MISSING index attribute

CB robot October 7, 2022 at 8:56 AM

Build couchbase-server-7.2.0-5000 contains query-ee commit 511c53f with commit message:
. Change ALLOW to INCLUDE

CB robot October 7, 2022 at 8:56 AM

Build couchbase-server-7.2.0-5000 contains query commit 02531bb with commit message:
. Leading Index Key MISSING

CB robot October 7, 2022 at 8:56 AM

Build couchbase-server-7.2.0-5000 contains query commit e6b0595 with commit message:
. Add optional ALLOW keyword before MISSING index attribute

Fixed
Pinned fields
Click on the next to a field label to start pinning.

Assignee

Ajay Pal Bhullar

Reporter

Priority

Instabug

Open Instabug
Created June 25, 2018 at 5:31 PM
Updated January 16, 2025 at 2:32 PM
Resolved May 18, 2022 at 9:00 PM
Instabug