BTRIM
Description
The BTRIM function is used to remove specified characters or spaces from both sides of the string str. If the trimStr parameter is not provided, all whitespace characters at both ends of the string are removed by default.
Parameter Description
- str (string): The original string that needs to be processed.
- trimStr (string, optional): Specifies the set of characters to be removed from both ends of the string.
Return Result
Returns the processed string.
Usage Example
Notes
- If the trimStr parameter is an empty string, the original string will not be modified.
- When the characters contained in the trimStr parameter do not exist in the original string, the function will still work properly and return the original string.
- If you need to remove characters in the middle of the string, consider using other string processing functions.