# WITH

> Add totals, percent change, running totals, group subtotals, a currency, or a time zone to a report.

`WITH` adds extras to a report.

```sql
FROM deals
SHOW won_value
GROUP BY owner
WITH TOTALS, PERCENT_CHANGE
DURING this_quarter
COMPARE TO previous_quarter
```

## Syntax

```sql
WITH <modifier>[, <modifier> ...]
```

`WITH` can follow `GROUP BY` or `TIMESERIES`, or stand on its own line.

| Modifier | What it adds |
|---|---|
| `TOTALS` | A totals row (in the API, a `totals` field) |
| `PERCENT_CHANGE` | The change against the comparison, as `percent_change_<metric>` columns (needs `COMPARE TO`) |
| `CUMULATIVE_VALUES` | A running total along the time grouping |
| `GROUP_TOTALS` | Subtotals for each value of the first grouping |
| `CURRENCY 'EUR'` | Money in that currency (the default is the workspace's base currency) |
| `TIMEZONE 'Asia/Amman'` | "Today" and "this month" read in that time zone |

## Examples

```sql
-- Running total of won revenue this year
FROM deals
SHOW won_value
TIMESERIES month
WITH CUMULATIVE_VALUES
DURING this_year
ON won_at
```

```sql
-- Orders in euros
FROM orders
SHOW total
GROUP BY payment_status
WITH CURRENCY 'EUR'
```

## Related pages

- [COMPARE TO](https://workstation.repzo.com/docs/analytics/repzoql/compare-to)
- [TIMESERIES](https://workstation.repzo.com/docs/analytics/repzoql/timeseries)
