CBSE Class 12 Informatics Practices Question 51 of 81

MySQL Functions — Question 2

Back to all questions
2
Question

Question 2(i)

Explain the UCASE() SQL function using suitable examples.

Answer

The UCASE()/UPPER() function converts the given string into uppercase. The syntax is UPPER(str) or UCASE(str). It returns the argument str with all letters capitalized, and the return value has the same data type as the argument str. For example,

SELECT UPPER('Large') "Uppercase";
Output
+-----------+
| Uppercase |
+-----------+
| LARGE     |
+-----------+