cockroachdb / cockroachdb/cockroach

sql/inspect: add INSPECT support for inverted indexes

Open
#154,859 0 comments 0 reactions 0 assignees View on GitHub
C-enhancement T-sql-foundations
Dominant language
Go
Stars
32.5k
Forks
4.1k
PR merge metrics
PR metrics pending

Description

Currently, INSPECT skips consistency checks on inverted indexes. These indexes differ from regular secondary indexes since a single primary key row can produce multiple inverted entries (one per token or element). To fully support them, INSPECT needs logic to reconstruct and validate token-to-row mappings.

- Define validation semantics for inverted index entries (e.g., per token or per source row).
- Add decoding and comparison support in the index consistency checker.
- Verify correctness using JSON, ARRAY, and spatial inverted index cases.

Jira issue: CRDB-55170

Epic CRDB-55075

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.