The UCASE() function in MySQL is used to convert all characters in a string to uppercase. It is a synonym for the UPPER() function. The syntax for using UCASE() is:
UCASE(string)
- string: The input string that you want to convert to uppercase.
Example:
SELECT UCASE('hello world');
This query will return:
HELLO WORLD
Notes:
- The
UCASE()function is case-insensitive by default, meaning it will convert all lowercase letters to uppercase. - It can be used in
SELECTstatements,WHEREclauses, or in combination with other string functions.
No comments:
Post a Comment