Package org.apache.calcite.rel.metadata
Interface BuiltInMetadata.PopulationSize
-
- All Superinterfaces:
Metadata
- Enclosing class:
- BuiltInMetadata
public static interface BuiltInMetadata.PopulationSize extends Metadata
Metadata about the number of distinct values in the original source of a column or set of columns.
-
-
Nested Class Summary
Nested Classes Modifier and Type Interface Description static interface
BuiltInMetadata.PopulationSize.Handler
Handler API.
-
Field Summary
Fields Modifier and Type Field Description static MetadataDef<BuiltInMetadata.PopulationSize>
DEF
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description java.lang.Double
getPopulationSize(ImmutableBitSet groupKey)
Estimates the distinct row count in the original source for the givengroupKey
, ignoring any filtering being applied by the expression.
-
-
-
Field Detail
-
DEF
static final MetadataDef<BuiltInMetadata.PopulationSize> DEF
-
-
Method Detail
-
getPopulationSize
java.lang.Double getPopulationSize(ImmutableBitSet groupKey)
Estimates the distinct row count in the original source for the givengroupKey
, ignoring any filtering being applied by the expression. Typically, "original source" means base table, but for derived columns, the estimate may come from a non-leaf rel such as a LogicalProject.- Parameters:
groupKey
- column mask representing the subset of columns for which the row count will be determined- Returns:
- distinct row count for the given groupKey, or null if no reliable estimate can be determined
-
-