MySQL UPPER() Function

In MySQL, the UPPER() function converts the specified string to upper and returns it.

The UPPER() function is the same as UCASE() function.

If you want to convert a string to lowercase, use the LCASE() or LOWER().

UPPER() Syntax

Here is the syntax of MySQL UPPER() function:

UPPER(str)

Parameters

str
Required. The string to be processed.

Return value

The UPPER(str) function returns the uppercase form of the specified string.

The function will NULL return when the str parameter is NULL.

UPPER() Examples

SELECT UPPER('Hello'), UPPER(NULL);
+----------------+--------------------------+
| UPPER('Hello') | UPPER(NULL)              |
+----------------+--------------------------+
| hello          | NULL                     |
+----------------+--------------------------+