In PostgreSQL, the UPPER function is used to convert a string into upper case.
Syntax: UPPER(string_expression)
Like the LOWER function, the UPPER function accepts a string expression or string-convertible expression and converts it to an upper case format. In case the argument is not a string, the user must use the CAST function to explicitly convert it.
Example 1:
The following statement uses the CONCAT function and UPPER function to return the full name of staff in the upper case from the staff table of the
SELECT
CONCAT (
UPPER (first_name),
UPPER (last_name)
) as full_name
FROM
staff;
Output:

Example 2:
The following statement converts a lower case string to an upper case format:
SELECT UPPER('geeksforgeeks');
Output:

Whether you're preparing for your first job interview or aiming to upskill in this ever-evolving tech landscape, GeeksforGeeks Courses are your key to success. We provide top-quality content at affordable prices, all geared towards accelerating your growth in a time-bound manner. Join the millions we've already empowered, and we're here to do the same for you. Don't miss out - check it out now!
Looking for a place to share your ideas, learn, and connect? Our Community portal is just the spot! Come join us and see what all the buzz is about!
Last Updated :
28 Aug, 2020
Like Article
Save Article
Share your thoughts in the comments
Please Login to comment...