Home » MySQL String Trim() Function

MySQL String Trim() Function

by Online Tutorials Library

MySQL Trim() Function

The trim() is a String function of MySQL. This function removes the blank spaces from the head and tail of the given string.

Syntax

Parameter:

str: string to be trimmed

leading: it removes blank spaces from the front of string

trainling: it removes blank spaces from the end of string

both: it removes blank spaces from front and end of the string

Example 1

Output:

MySQL String Trim() Function

Example 2

Output:

MySQL String Trim() Function

Example 3

Output:

MySQL String Trim() Function

Example 4

Output:

MySQL String Trim() Function

Next TopicMySQL String

You may also like