lower

Converts a string to lowercase.

Syntax

lower(<string>)

Arguments

ArgumentTypeDescription
<string>stringString to transform.

Returns

Returns string. Returns NULL if the input is NULL.

Examples

Normalize channel capitalization before counting checkout events.

VALUES ('Web'), ('WEB'), ('web'), ('Mobile'), ('mobile')
SELECT lower($0) AS channel
GROUP BY channel
AGGREGATE count() AS events
ORDER BY channel
+---------+--------+
| channel | events |
+---------+--------+
| mobile  | 2      |
| web     | 3      |
+---------+--------+