doc/user/content/sql/functions/normalize.md
normalize converts a string to a specified Unicode normalization form.
{{% include-example file="examples/normalize" example="syntax" %}}
| Parameter | Type | Description |
|---|---|---|
| str | string | The string to normalize. |
| form | keyword | The Unicode normalization form: NFC, NFD, NFKC, or NFKD (unquoted, case-insensitive keywords). Defaults to NFC. |
normalize returns a string.
Unicode normalization is a process that converts different binary representations of characters to a canonical form. This is useful when comparing strings that may have been encoded differently.
The four normalization forms are:
For more information, see:
{{% include-example file="examples/normalize" example="normalize-default" %}}
<hr/>{{% include-example file="examples/normalize" example="normalize-nfc" %}}
<hr/>{{% include-example file="examples/normalize" example="normalize-nfd" %}}
<hr/>{{% include-example file="examples/normalize" example="normalize-nfkc-ligatures" %}}
<hr/>{{% include-example file="examples/normalize" example="normalize-nfkc-superscript" %}}