PLSQL | LTRIM Function Last Updated : 24 Sep, 2019 Comments Improve Suggest changes Like Article Like Report The PLSQL LTRIM function is used for removing all specified characters from the left-hand side of a string. The PLSQL LTRIM function accepts two parameters which are input_string and trim_string. If the user does not specify trim_string, it defaults to a single blank. If char is a character literal, then you must enclose it in single quotes. Oracle Database begins scanning char from its first character and removes all characters that appear in trim_string until reaching a character not in trim_string and then returns the result. Syntax: LTRIM( input_string [, trim_string] ) Parameters Used: input_string - It is used to specify the string whose characters need to be trimmed from the left hand side. trim_string - It is an optional parameter which is used to specify the string that will be removed from the left-hand side of string1. If this parameter is omitted, the LTRIM function removes all leading spaces from input_string. Supported Versions of Oracle/PLSQL: Oracle 12c Oracle 11g Oracle 10g Oracle 9i Oracle 8i Example-1: DECLARE Test_String string(25) := ' Geeksforgeeks'; BEGIN dbms_output.put_line(LTRIM(Test_String)); END; Output: Geeksforgeeks Example-2: DECLARE Test_String string(25) := ' Geeksforgeeks'; BEGIN dbms_output.put_line(LTRIM(Test_String, ' ')); END; Output: Geeksforgeeks Example-3: DECLARE Test_String string(25) := '123Geeksforgeeks'; BEGIN dbms_output.put_line(LTRIM(Test_String, '123')); END; Output: Geeksforgeeks Example-4: DECLARE Test_String string(25) := '123123Geeksforgeeks'; BEGIN dbms_output.put_line(LTRIM(Test_String, '123')); END; Output: Geeksforgeeks Example-5: DECLARE Test_String string(25) := '123Geeks123forgeeks'; BEGIN dbms_output.put_line(LTRIM(Test_String, '123')); END; Output: Geeks123forgeeks Comment More infoAdvertise with us Next Article PLSQL | LTRIM Function S Shubrodeep Banerjee Follow Improve Article Tags : SQL SQL-PL/SQL Similar Reads SQL LTRIM() Function The SQL LTRIM() function is an essential tool used in data cleaning and manipulation tasks. This function helps remove unwanted leading spaces or specific characters from the left side of a string or string expression. It's commonly used to tidy up data by eliminating unnecessary spaces or character 4 min read SQL RTRIM() Function SQL RTRIM function is a string function that removes spaces from the right side of a character or string. RTRIM or Right Trim function is used in data cleaning and manipulation in SQL.In this example, we will learn the basics of the RTRIM function, and learn how it works with examples of different u 4 min read PLSQL | LN Function The LN function is an inbuilt function in PLSQL which is used to return the natural logarithm of a given input number. The natural logarithm of a number is the logarithm of that number to the base e, where e is the mathematical constant approximately equal to 2.718. This is written using the notatio 2 min read PLSQL | LEAST Function The LEAST is an inbuilt function in PLSQL which is used to return the least value from a given list of some expressions. These expressions may be numbers, alphabets etc. Syntax: LEAST(exp1, exp2, ... exp_n) Parameters Used: This function accept some parameters like exp1, exp2, ... exp_n. These each 2 min read PLSQL | INSTR Function The PLSQL INSTR function is used for returning the location of a substring in a string. The PLSQL INSTR function searches a string for a substring specified by the user using characters and returns the position in the string that is the first character of a specified occurrence of the substring. The 2 min read Like