2021-01-04 14:34:22 +00:00
---
2022-08-28 14:53:34 +00:00
slug: /en/sql-reference/statements/select/all
2022-04-09 13:29:05 +00:00
sidebar_label: ALL
2021-01-04 14:34:22 +00:00
---
2022-06-02 10:55:18 +00:00
# ALL Clause
2021-01-04 14:34:22 +00:00
2021-03-01 13:51:38 +00:00
If there are multiple matching rows in the table, then `ALL` returns all of them. `SELECT ALL` is identical to `SELECT` without `DISTINCT` . If both `ALL` and `DISTINCT` specified, exception will be thrown.
2021-01-04 14:34:22 +00:00
`ALL` can also be specified inside aggregate function with the same effect(noop), for instance:
```sql
SELECT sum(ALL number) FROM numbers(10);
```
equals to
```sql
SELECT sum(number) FROM numbers(10);
```
2021-03-01 13:51:38 +00:00
2021-09-19 20:05:54 +00:00
[Original article ](https://clickhouse.com/docs/en/sql-reference/statements/select/all ) <!--hide-->