Received: from localhost (unknown [200.46.204.191]) by postgresql.org (Postfix) with ESMTP id ACA372E2FCB for ; Fri, 25 Jan 2008 12:17:57 -0400 (AST) Received: from postgresql.org ([200.46.204.71]) by localhost (mx1.hub.org [200.46.204.191]) (amavisd-maia, port 10024) with ESMTP id 87773-02 for ; Fri, 25 Jan 2008 12:17:54 -0400 (AST) Received: from mail.ringways.co.uk (hub.ringways.co.uk [80.193.83.130]) by postgresql.org (Postfix) with ESMTP id 25BFC2E2FB3 for ; Fri, 25 Jan 2008 12:17:54 -0400 (AST) Received: from eddie.ringways.co.uk ([10.1.1.115]) by mail.ringways.co.uk with esmtp (Exim 4.62) (envelope-from ) id 1JIR91-0007OK-MJ for pgsql-sql@postgresql.org; Fri, 25 Jan 2008 16:11:07 +0000 From: Gary Stainburn Organization: Ringways Garages Ltd To: pgsql-sql@postgresql.org Subject: regex_replace problem Date: Fri, 25 Jan 2008 16:15:58 +0000 User-Agent: KMail/1.9.5 MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Content-Disposition: inline Message-Id: <200801251615.59186.gary.stainburn@ringways.co.uk> X-Virus-Scanned: Maia Mailguard 1.0.1 X-Archive-Number: 200801/192 X-Sequence-Number: 30045 Hi folks. I've got a problem with regex_replace. As you can see below psql displays the error saying the function does not exist. Can anyone see why, and what I need todo to fix it. Cheers goole=# select distinct ud_rfl from used_diary where ud_rfl ~ ' *= *'; ud_rfl ----------- 12 = 1wk 12=1WK 12m = 1wk 6=1WK (4 rows) goole=# select distinct regex_replace(ud_rfl,' *= *','+') from used_diary where ud_rfl ~ ' *= *'; ERROR: function regex_replace(character varying, "unknown", "unknown") does not exist HINT: No function matches the given name and argument types. You may need to add explicit type casts. goole=# select distinct replace(ud_rfl,'=','+') from used_diary where ud_rfl ~ ' *= *'; replace ----------- 12 + 1wk 12+1WK 12m + 1wk 6+1WK (4 rows) [root@stan ~]# rpm -qa|grep postgresql postgresql-jdbc-8.1.9-1.fc5 postgresql-libs-8.1.9-1.fc5 postgresql-pl-8.1.9-1.fc5 postgresql-contrib-8.1.9-1.fc5 postgresql-server-8.1.9-1.fc5 postgresql-docs-8.1.9-1.fc5 postgresql-python-8.1.9-1.fc5 postgresql-8.1.9-1.fc5 postgresql-test-8.1.9-1.fc5 postgresql-tcl-8.1.9-1.fc5 [root@stan ~]# -- Gary Stainburn This email does not contain private or confidential material as it may be snooped on by interested government parties for unknown and undisclosed purposes - Regulation of Investigatory Powers Act, 2000