Re: Simple SQL question
- From: "Mahesh Rajendran" <Magvivek@xxxxxxxxx>
- Date: 31 Jan 2006 10:01:33 -0800
--
-- in 10g
-- Thanks to Aketi. http://oraclesqlpuzzle.hp.infoseek.co.jp/
--
SCOTT > ed
Wrote file afiedt.buf
1 select regexp_replace('the cat sat on the mat', ' {2,}', '
')
2* from dual
SCOTT > /
REGEXP_REPLACE('THECAT
----------------------
the cat sat on the mat
SCOTT > ed
Wrote file afiedt.buf
1* select regexp_replace('the cat sat on the mat',' +',' ')
from dual
SCOTT > /
REGEXP_REPLACE('THECAT
----------------------
the cat sat on the mat
--
-- In 9i
--
SCOTT > ed
Wrote file afiedt.buf
1* select replace(replace('the cat sat on the mat',' ','
'),' ',' ') from dual
SCOTT > /
REPLACE(REPLACE('THECA
----------------------
the cat sat on the mat
.
- Follow-Ups:
- Re: Simple SQL question
- From: yong321
- Re: Simple SQL question
- References:
- Simple SQL question
- From: Jeremy
- Simple SQL question
- Prev by Date: Re: Simple SQL question
- Next by Date: Re: Simple SQL question
- Previous by thread: Re: Simple SQL question
- Next by thread: Re: Simple SQL question
- Index(es):
Relevant Pages
|