TITLE()
All functions > STRING > TITLE()
Returns the string with the first letter of each whitespace-delimited word in uppercase and the remaining letters in lowercase.
Signatures
Returns: Title-cased string
TITLE(string: VARCHAR) → VARCHAR sql
| Parameter | Type | Required | Description |
|---|---|---|---|
string | VARCHAR | Yes | Input string to convert |
Notes
- Whitespace separates words; leading and trailing whitespace are trimmed first, and words in the result are separated by a single space
- Letters are adjusted per word; digits, punctuation, and symbols other than word boundaries typically remain in place
TITLE('')is''; if the input is NULL the result is NULL (useNULL(VARCHAR); bareNULLfails inference)INITCAP(...)is an alias forTITLE(...)and behaves the same
Aliases
INITCAP
Examples
FeatureQL
SELECT
f1 := TITLE('hello world'), -- Two words
f2 := TITLE('HELLO WORLD'), -- From all caps
f3 := INITCAP('mixed CASE text'), -- INITCAP alias matches TITLE
f4 := TITLE('café au lait'), -- Accented letters
f5 := TITLE(NULL(VARCHAR)) -- NULL yields NULL
;Result
| f1 VARCHAR | f2 VARCHAR | f3 VARCHAR | f4 VARCHAR | f5 VARCHAR |
|---|---|---|---|---|
| Hello World | Hello World | Mixed Case Text | Café Au Lait | NULL |
On this page