Applies to: ✅ Data 360 SQL ✅ Tableau Hyper API
Returns the number of characters in a string.
Syntax
length(<string>)
Arguments
Required
<string>: The string to measure.
Returns
Returns an integer that represents the number of characters.
Considerations
- Equivalent to
char_lengthandcharacter_length. - Counts characters, not bytes.
Examples
Get String Length
Count characters in a string.
SELECT length('jose') AS result;
Returns 4.