pub struct ColumnStats {
pub name: String,
pub ndv: u64,
pub null_fraction: f64,
pub min_value: Option<f64>,
pub max_value: Option<f64>,
}Expand description
Column statistics
Fields§
§name: StringColumn name
ndv: u64Number of distinct values (NDV)
null_fraction: f64Fraction of NULL values
min_value: Option<f64>Minimum value (for numeric columns)
max_value: Option<f64>Maximum value (for numeric columns)
Implementations§
Source§impl ColumnStats
impl ColumnStats
Sourcepub fn new(name: String) -> ColumnStats
pub fn new(name: String) -> ColumnStats
Create new column stats
Sourcepub fn with_ndv(self, ndv: u64) -> ColumnStats
pub fn with_ndv(self, ndv: u64) -> ColumnStats
Set NDV
Sourcepub fn with_null_fraction(self, fraction: f64) -> ColumnStats
pub fn with_null_fraction(self, fraction: f64) -> ColumnStats
Set null fraction
Sourcepub fn with_range(self, min: f64, max: f64) -> ColumnStats
pub fn with_range(self, min: f64, max: f64) -> ColumnStats
Set min/max values
Sourcepub fn equality_selectivity(&self) -> f64
pub fn equality_selectivity(&self) -> f64
Estimate selectivity for equality predicate
Trait Implementations§
Source§impl Clone for ColumnStats
impl Clone for ColumnStats
Source§fn clone(&self) -> ColumnStats
fn clone(&self) -> ColumnStats
Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreAuto Trait Implementations§
impl Freeze for ColumnStats
impl RefUnwindSafe for ColumnStats
impl Send for ColumnStats
impl Sync for ColumnStats
impl Unpin for ColumnStats
impl UnsafeUnpin for ColumnStats
impl UnwindSafe for ColumnStats
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<T> Instrument for T
impl<T> Instrument for T
Source§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
Source§fn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self>
fn into_either(self, into_left: bool) -> Either<Self, Self>
Converts
self into a Left variant of Either<Self, Self>
if into_left is true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
Converts
self into a Left variant of Either<Self, Self>
if into_left(&self) returns true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§impl<T> IntoRequest<T> for T
impl<T> IntoRequest<T> for T
Source§fn into_request(self) -> Request<T>
fn into_request(self) -> Request<T>
Wrap the input message
T in a tonic::Request