---
title: - (subtract)
slug: subtract
createdAt: 2021-09-14T17:53:05.000Z
---

An operator used to subtract an expression from another expression.

### Syntax

`valueOne - valueTwo`

### Sample usage

`(1 - 2) - 3` returns `-4`

`('2021-01-02') - 1` returns `2021-01-01`

### Supported data types

- 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 `Date`the 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`.

### See also

- [Number](https://docs.charthop.com/ucI5-number)
- [Money](https://docs.charthop.com/_kS5-money)&#x20;
- [Percent](https://docs.charthop.com/FbN7-percent)&#x20;
- [String](https://docs.charthop.com/string)&#x20;
- [Date](https://docs.charthop.com/date)
- [+ (add)](https://docs.charthop.com/add)&#x20;

