INITCAP
INITCAP(string)
Section titled “INITCAP(string)”- string: It refers to the input string on which the INITCAP function is to be applied. This function converts the first letter of each word in the string to uppercase and the rest to lowercase.
Example
Section titled “Example”SELECT INITCAP('hello WORLD') AS Sample_Output FROM dual;Output
Section titled “Output”SAMPLE_OUTPUTHello WorldExplanation
Section titled “Explanation”The INITCAP function in Oracle is used to convert the first letter of each word to uppercase, while the rest of the characters in the word are converted to lowercase. In the given example, ‘hello WORLD’ is converted to ‘Hello World’.
INITCAP(text) RETURNS text
Section titled “INITCAP(text) RETURNS text”- text: This is the input string that the INITCAP() function will process. It converts the first letter of each word in the text string to uppercase and the remaining to lowercase.
Example
Section titled “Example”SELECT INITCAP('hello world');Output
Section titled “Output”'Hello World'Explanation
Section titled “Explanation”In this example, the INITCAP function modifies the given string ‘hello world’ by capitalizing the first letter of each word, resulting in ‘Hello World’.