SQL LTRIM() is an inbuilt function that is used for removing all the leading whitespaces or specified characters from the string, i.e. from the left-hand side of the string. In this tutorial, you will learn how to use a MySQL and SQL Server LTRIM() function to remove leading blanks from a string. Oracle/PLSQL LTRIM function removes all specified characters from the left-hand side of a string.
The LTRIM() function returns the string after removing leading blanks.
The following shows the syntax of the LTRIM() function.
SELECT LTRIM (input_string, [trim_string])
Input_string: It is the string from where the characters have to be removed from the left-hand side.
Trim_string: It is completely optional. It is mainly used for specifying the characters to be removed. If this parameter is omitted, then all the leading spaces will be removed.
#sql #sql ltrim #mysq #sql server