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

Home -> Community -> Mailing Lists -> Oracle-L -> RE:

RE:

From: LGE <elkinsl_at_flash.net>
Date: Mon, 18 Sep 2000 18:13:38 -0500
Message-Id: <10623.117295@fatcity.com>


Christine,

Try using the REPLACE function within an update statement:

SQL> select * from foo;

FOO


E:\April30 backup\daily_gl_baleom.prn
E:\May30 backup\dailyglbal.prn
E:\Jun30 backup\BORROWALS30.LST
E:\Jun30 backup\dda30.LST
E:\Jun30 backup\loans30.LST

SQL> Update Foo
  2 Set Foo = replace(foo,'E:\Jun30 backup\','\\ServerName\backup\')   3 Where Foo Like 'E:\Jun30 backup\%'   4 /

3 rows updated.

SQL> select * from foo;

FOO



E:\April30 backup\daily_gl_baleom.prn
E:\May30 backup\dailyglbal.prn
\\ServerName\backup\BORROWALS30.LST
\\ServerName\backup\dda30.LST
\\ServerName\backup\loans30.LST

If you are absolutely sure of the mixed case, the above is fine. If there is a chance of various cases, you might want to do an UPPER('E:\Jun30 backup\') in the replace and an UPPER in the WHERE clause.

Regards,

L. Elkins

-----Original Message-----
From: root_at_fatcity.com [mailto:root_at_fatcity.com]On Behalf Of Christine Turner
Sent: Monday, September 18, 2000 4:47 PM To: Multiple recipients of list ORACLE-L Subject:

Hello All.........

I have an interesting request from a co-worker of mine. Listed below is a sub-set of data from a table in one of our databases. The request was a basic search and replace. Find all columns with the string "E:\Jun30 backup\" in them and replace it with "\\ServerName\backup\".

PATH_NAME



E:\April30 backup\daily_gl_baleom.prn
E:\May30 backup\dailyglbal.prn
E:\Jun30 backup\BORROWALS30.LST
E:\Jun30 backup\dda30.LST
E:\Jun30 backup\loans30.LST

Anyone have ANY ideas???? I'm a little stumped so any help is appreciated.

Thanks!!!
Christine Turner
DBA
IPS Sendero
Scottsdale, Arizona

--
Author: Christine Turner
  INET: christine.turner_at_ips-sendero.com

Fat City Network Services    -- (858) 538-5051  FAX: (858) 538-5051
San Diego, California        -- Public Internet access / Mailing Lists
--------------------------------------------------------------------
To REMOVE yourself from this mailing list, send an E-Mail message
to: ListGuru_at_fatcity.com (note EXACT spelling of 'ListGuru') and in
the message BODY, include a line containing: UNSUB ORACLE-L
(or the name of mailing list you want to be removed from).  You may
Received on Mon Sep 18 2000 - 18:13:38 CDT

Original text of this message

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