pub fn explain_cardinality<R: TryRead>(
snap: &R,
tenant: TenantId,
labels: &[String],
where_: &Expr,
) -> Result<Option<u64>, QueryError>Expand description
Exact most-selective index-leaf cardinality for a predicate, for EXPLAIN
. Uses the maintained derived posting cardinality when the view
carries it, so EXPLAIN need not materialize candidates. Returns None
when no leaf is index-eligible (a full scan).
ยงErrors
Propagates storage/engine read errors from the estimate lookup.