X-Original-To: pgsql-sql-postgresql.org@localhost.postgresql.org Received: from localhost (av.hub.org [200.46.204.144]) by svr1.postgresql.org (Postfix) with ESMTP id 937BBDB9BF for ; Thu, 17 Nov 2005 20:13:11 -0400 (AST) Received: from svr1.postgresql.org ([200.46.204.71]) by localhost (av.hub.org [200.46.204.144]) (amavisd-new, port 10024) with ESMTP id 87242-06 for ; Fri, 18 Nov 2005 00:13:13 +0000 (GMT) X-Greylist: from auto-whitelisted by SQLgrey- Received: from presinet.com (presinet.com [209.53.156.1]) by svr1.postgresql.org (Postfix) with ESMTP id DDA68DB466 for ; Thu, 17 Nov 2005 20:13:08 -0400 (AST) Received: from [10.10.1.151] ([10.10.1.151]) by presinet.com with Microsoft SMTPSVC(6.0.3790.1830); Thu, 17 Nov 2005 16:10:49 -0800 Message-ID: <437D1C75.4080409@PresiNET.com> Date: Thu, 17 Nov 2005 16:12:37 -0800 From: Bricklen Anderson User-Agent: Debian Thunderbird 1.0.7 (X11/20051017) X-Accept-Language: en-us, en MIME-Version: 1.0 To: Dawn Buie CC: pgsql-sql@postgresql.org Subject: Re: how to do a find and replace References: <1132269492.30942.20.camel@dev11dt.corp.localmatters.com> <5d001d303f001ea0847254c3f0a352d9@squeegeemedia.com> <437D1862.2060402@PresiNET.com> In-Reply-To: Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit X-OriginalArrivalTime: 18 Nov 2005 00:10:49.0609 (UTC) FILETIME=[87EEB790:01C5EBD4] X-Virus-Scanned: by amavisd-new at hub.org X-Spam-Status: No, score=0 required=5 tests=[AWL=0.000] X-Spam-Score: 0 X-Spam-Level: X-Archive-Number: 200511/142 X-Sequence-Number: 23393 Dawn Buie wrote: > I used: > > update media_instance set location=replace(location,'v.','') > where location like '%/0/v.%' > > and that did work- > > thank you very much. > > it seems to me that the replace function is the same as translate()- no? > Right, I forgot your WHERE clause. Some more details on those functions can be found here: http://www.postgresql.org/docs/8.1/interactive/functions-string.html#FUNCTIONS-STRING-OTHER -- _______________________________ This e-mail may be privileged and/or confidential, and the sender does not waive any related rights and obligations. Any distribution, use or copying of this e-mail or the information it contains by other than an intended recipient is unauthorized. If you received this e-mail in error, please advise me (by return e-mail or otherwise) immediately. _______________________________