On 24/09/2010 5:15 PM, Nicholas I wrote:

Example:
table name person:

name
------------------------------------
Samuel (S/o Sebastin )
-------------------------------------

remove the word within the brackets.
the output should be , Samuel.

Can't you just regexp_replace, matching \([^)]+\) (in other words "an open parenthisis, then a sequence of one or more of any character other than a close parenthesis, followed by a close parentheis) and replacing with an empty string ?

--
Craig Ringer

Tech-related writing at http://soapyfrogs.blogspot.com/

--
Sent via pgsql-sql mailing list (pgsql-sql@postgresql.org)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-sql

Reply via email to