Working with String Values

Learn about built-in functions that make it easier to work with string values.

T-SQL has many built-in functions that we can use to work with strings and text. Functions can be applied to a single value or to a whole column when selecting. To view the result of a function call, we can use the SELECT statement:

SELECT FUNCTION(Parameter)

Finding the length

We can count the number of characters in a given string value using the LEN() function. The function considers space as a character:

Get hands-on with 1400+ tech skills courses.