Received: from localhost (maia-1.hub.org [200.46.204.191]) by postgresql.org (Postfix) with ESMTP id AD8139FB591 for ; Thu, 12 Apr 2007 16:51:32 -0300 (ADT) Received: from postgresql.org ([200.46.204.71]) by localhost (mx1.hub.org [200.46.204.191]) (amavisd-maia, port 10024) with ESMTP id 82951-04 for ; Thu, 12 Apr 2007 16:51:24 -0300 (ADT) X-Greylist: from auto-whitelisted by SQLgrey-1.7.4 Received: from svr4.postgresql.org (svr4.postgresql.org [66.98.251.159]) by postgresql.org (Postfix) with ESMTP id 1D4C59FB510 for ; Thu, 12 Apr 2007 16:51:24 -0300 (ADT) X-Greylist: domain auto-whitelisted by SQLgrey-1.7.3 Received: from ns2.instrumentalyst.com (blk-222-55-203.eastlink.ca [24.222.55.203]) by svr4.postgresql.org (Postfix) with ESMTP id 531965AF04F for ; Thu, 12 Apr 2007 19:51:23 +0000 (GMT) Received: from localhost (localhost [127.0.0.1]) by ns2.instrumentalyst.com (Postfix) with ESMTP id B510B144C; Thu, 12 Apr 2007 16:37:47 -0300 (ADT) X-Virus-Scanned: amavisd-new at instrumentalyst.com Received: from ns2.instrumentalyst.com ([127.0.0.1]) by localhost (ns2.instrumentalyst.com [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id NGwpKb-XOjy9; Thu, 12 Apr 2007 16:37:41 -0300 (ADT) Received: from murdoc.home (pool-71-180-50-145.tampfl.fios.verizon.net [71.180.50.145]) by ns2.instrumentalyst.com (Postfix) with ESMTP id 605BD1438; Thu, 12 Apr 2007 16:37:41 -0300 (ADT) Message-ID: <461E8DAB.6090504@productivitymedia.com> Date: Thu, 12 Apr 2007 15:51:07 -0400 From: PostgreSQL Admin User-Agent: Thunderbird 2.0.0.0 (Macintosh/20070326) MIME-Version: 1.0 To: "A. Kretschmer" Cc: pgsql-sql@postgresql.org, =?ISO-8859-1?Q?Rodrigo_De_Le=F3n?= Subject: Re: Replace string References: <461BF649.70204@productivitymedia.com> <20070412051250.GB27660@a-kretschmer.de> In-Reply-To: <20070412051250.GB27660@a-kretschmer.de> Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit X-Virus-Scanned: Maia Mailguard 1.0.1 X-Spam-Status: No, hits=0.186 tagged_above=0 required=5 tests=AWL=0.050, BAYES_50=0.001, FORGED_RCVD_HELO=0.135 X-Spam-Level: X-Archive-Number: 200704/133 X-Sequence-Number: 28133 > test=*# select regexp_replace(regexp_replace('The blue fox\'s fur.', ' ', '-', 'g'), '\\.', ''); > regexp_replace > -------------------- > The-blue-fox's-fur > (1 row) > > > Andreas > Thanks for the input. I came up with this: REPLACE(regexp_replace('The blue fox\'s fur', '[[:punct:]]', ''), ' ', '-');