Trusted answers to developer questions
Trusted Answers to Developer Questions

Related Tags

sql
mysql
upper
communitycreator

What is UPPER() in SQL?

Harris Amjad

Grokking Modern System Design Interview for Engineers & Managers

Ace your System Design Interview and take your career to the next level. Learn to handle the design of applications like Netflix, Quora, Facebook, Uber, and many more in a 45-min interview. Learn the RESHADED framework for architecting web-scale applications by determining requirements, constraints, and assumptions before diving into a step-by-step design process.

The UPPER() function converts a string sent as a parameter to uppercase.

Figure 1 shows a visual representation of the UPPER() function.

Figure 1: Visual representation of UPPER() function

Syntax

UPPER(string)

Parameter

The UPPER() function takes in a string that needs to be converted to uppercase as a required parameter.

Return value

The UPPER() function returns the uppercase version of a string sent as a parameter.

If a number is sent as a parameter, then UPPER() returns the number unchanged.

Code

-- string
SELECT UPPER('hello');

-- number
SELECT UPPER(123);

RELATED TAGS

sql
mysql
upper
communitycreator

Grokking Modern System Design Interview for Engineers & Managers

Ace your System Design Interview and take your career to the next level. Learn to handle the design of applications like Netflix, Quora, Facebook, Uber, and many more in a 45-min interview. Learn the RESHADED framework for architecting web-scale applications by determining requirements, constraints, and assumptions before diving into a step-by-step design process.

Keep Exploring