Re: trim(both) problem? - Mailing list pgsql-sql

From Emi Lu
Subject Re: trim(both) problem?
Date
Msg-id 4815CEC7.4060405@encs.concordia.ca
Whole thread Raw
In response to Re: trim(both) problem?  (Tom Lane <tgl@sss.pgh.pa.us>)
List pgsql-sql
Thanks a lot for all help! I understand how trim work now.

>> You could probably use instead:
>> select replace('<BR/>ROI Engineering Inc.', '<BR/>', '')

> That would zap occurrences in the middle of the string, though.
> regexp_replace would be better since it'd allow anchoring the
> pattern, eg
> 
> select regexp_replace('<BR/>ROI Engineering Inc.', '^<BR/>', '');
> select regexp_replace('ROI Engineering Inc.<BR/>', '<BR/>$', '');

This is exactly I am looking for, but my version
PostgreSQL 8.0.15 on i686-pc-linux-gnu, compiled by GCC gcc (GCC) 3.3.2

does not support this func, and have to think about the other way to 
'trim' the ^<BR/> & <BR>$

Thank you again!


pgsql-sql by date:

Previous
From: Alvaro Herrera
Date:
Subject: Re: psql: no schema info
Next
From: chester c young
Date:
Subject: Re: psql: no schema info