Carrot reference
Operators
- (subtract)
An operator used to subtract an expression from another expression.
valueOne - valueTwo
(1 - 2) - 3 returns -4
('2021-01-02') - 1 returns 2021-01-01
- If a Number, Money value, or Percent is subtracted from an expression of the same type, the difference between the two values will be returned.
- If the left side is a Date, and the right side is a Number, it will return the date minus that many days.
- Date is subtracted from another Datethe number of days between them will be returned.
- If a Number value is subtracted from a Money value, the Money value will decrease by the value of the Number.
- If a Percent value is subtracted from a Number value, the Number value will decrease by the value of the Percent; the reverse operation will also work, however the returned value will still be of type Number.