divide method
Expr<T>
divide(
- Decimal divisor, {
- required int scale,
- DecimalRounding rounding = DecimalRounding.exact,
Divides in SQL to an explicit scale without a floating-point intermediate.
Implementation
Expr<T> divide(
Decimal divisor, {
required int scale,
DecimalRounding rounding = DecimalRounding.exact,
}) {
Decimal.validateScale(scale);
return Expr.internal(
DecimalRatio(
expressionNode,
value(divisor, Codecs.decimal).expressionNode,
scale,
rounding,
),
codec,
);
}