# upper

[Read this page in HTML](https://www.scopedb.io/docs/reference/functions/string/upper)

Converts a string to uppercase.

## Syntax

```scopeql
upper(<string>)
```

## Arguments

| Argument   | Type     | Description          |
| ---------- | -------- | -------------------- |
| `<string>` | `string` | String to transform. |

## Returns

Returns `string`. Returns NULL if the input is NULL.

## Examples

Put region codes from different event producers into one representation before grouping.

```scopeql
VALUES ('us'), ('US'), ('gb'), ('Gb')
SELECT upper($0) AS region
GROUP BY region
AGGREGATE count() AS events
ORDER BY region
```

```text
+--------+--------+
| region | events |
+--------+--------+
| GB     | 2      |
| US     | 2      |
+--------+--------+
```
