Oracle FAQ Your Portal to the Oracle Knowledge Grid
HOME | ASK QUESTION | ADD INFO | SEARCH | E-MAIL US
 

Home -> Community -> Usenet -> c.d.o.server -> Re: Replace string, help!

Re: Replace string, help!

From: Nick Pope <nick.pope_at_retaininternational.com>
Date: Fri, 16 Feb 2001 10:37:30 -0000
Message-ID: <t8q10kibcgp2a@xo.supernews.co.uk>

You need to use a mixture of SUBSTR, INSTR

Assuming the simplest example where the column begins with the text 'MY CAR'... update table
set column_name = 'MY OLD CAR'¦¦substr(column_name,8) where column_name like '%MY CAR%'

If the column does not begin with the text, but has it somewhere in the midde, you will need to use INSTR to locate where the text you want to replace resides.

Nick Received on Fri Feb 16 2001 - 04:37:30 CST

Original text of this message

HOME | ASK QUESTION | ADD INFO | SEARCH | E-MAIL US