subtract( )


Developer Preview

This API is subject to change. Bug fixes and new features will be released based on developer feedback throughout the preview period.

Subtracts 1 expression from another.

The subtract() method configures the aggregation pipeline to subtract the second expression from the first expression.

Method Declaration
Copy
Method Parameters
firstExpression

Expression to subtract second from. Expression must resolve to a number.


secondExpression

Expression to subtract from first. Expression must resolve to a number.

Returns
Return Type:SubtractExpression
Errors

This method doesn't return any custom errors, but may return standard errors. Learn more about standard Wix errors.

Did this help?