Saturday, 24 September 2016

SQL Query to remove whitespace character from string in SQL Server.

SQL TRIM() function

Description:

In this example we explain that how to TRIM the string in SQL Server or how to remove the white space in string in SQL Server.SQL Query to remove the white space character from string in SQL Server. fetch string with trimming the white space character form string in SQL Server.

Here we use TRIM() function of the SQL Server to remove the whitespace character.here we use LTRIM() and RTRIM() function of the SQL Server to remove left side and right side whitespace character from string.
Query:

SELECT RTRIM('Hello   ')

SELECT LTRIM('    Hello')
This entry was posted in :

2 comments: