postgres=# SELECT rtrim('whitespace example '); rtrim -------------------- whitespace example (1 row)