Skip to main content

log10

Function log10 

Source
pub fn log10<'a, V, E>(
    expr: E,
) -> SQLExpr<'a, V, <V::DialectMarker as DialectTypes>::Double, E::Nullable, E::Aggregate>
where V: SQLParam + 'a, E: Expr<'a, V>, E::SQLType: Numeric,
Expand description

LOG10 - returns the base-10 logarithm of a number.

Returns a dialect-aware double type, preserves nullability.

ยงExample

use drizzle_core::expr::log10;

// SELECT LOG10(users.value)
let log_base_10 = log10(users.value);