Skip to main content
Module

x/mongoose/types/expressions.d.ts>mongoose.Expression.Subtract

MongoDB object modeling designed to work in an asynchronous environment.
Go to Latest
interface mongoose.Expression.Subtract
import { type mongoose } from "https://deno.land/x/mongoose@6.7.5/types/expressions.d.ts";
const { Subtract } = mongoose.Expression;

Properties

Returns the result of subtracting the second value from the first. If the two values are numbers, return the difference. If the two values are dates, return the difference in milliseconds. If the two values are a date and a number in milliseconds, return the resulting date. Accepts two argument expressions. If the two values are a date and a number, specify the date argument first as it is not meaningful to subtract a date from a number.