I am taking data from the users which can be very unreliable. So before saving it in the PostgreSQL DB, I have to clear all the extra character in the beginning and the ending of the string.
Is this Possible to achieve?
' \n \t \n \r\n abc_def_\n xyz \r\n ' to 'abc_def_\n xyz'Are there any more whitespace like characters that I should care about?
\n newline \r carriage return \t horizontal tab whitespace
