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

Home -> Community -> Usenet -> c.d.o.misc -> Re: Finding data with spaces in them.

Re: Finding data with spaces in them.

From: Prince Of Thieves <thief_NOSPAM_at_hotmail.com>
Date: Thu, 27 Nov 2003 16:12:33 +1100
Message-ID: <REfxb.119$zW.3420@nnrp1.ozemail.com.au>


Thanks Hans & Daniel.

-- 

Julian Milano


"Daniel Morgan" <damorgan_at_x.washington.edu> wrote in message
news:1069892374.117982_at_yasure...

> Prince Of Thieves wrote:
> > Daniel,
> >
> > Didn't you read my original post:
> >
> > SELECT STYLECODE, ACTIVE FROM STYLE WHERE REPLACE (STYLECODE, ' ', '')
> > IN (SELECT REPLACE (STYLECODE, ' ','')
> > FROM STYLE
> > GROUP BY REPLACE (STYLECODE, ' ','')
> > HAVING COUNT (*)>1);
> >
> > Sorry!
> >
> >
> >>>The second statement replaces any double spaces it finds ' ' with
> >>
> >>single spaces ' '.
> >
> >
> > I gathered that, but it returns the following data:
> >
> > SAT 4346 0
> > SAT4346 1
> > RIB 1731 1
> > RIB1731 1
> >
> > Which is what intrigued me! It returns the codes with AND without spaces
in
> > the code! I just want to know how this works.
> >
> > Thanks for your reply.
>
> Pretty obvious to me. The code converts two spaces to one where it finds
> them. So what does it do when it finds 10 spaces? Converts them to 5.
> What does it do when it finds 7 spaces? Converts them to 4: Just do the
> math.
>
> --
> Daniel Morgan
> http://www.outreach.washington.edu/ext/certificates/oad/oad_crs.asp
> http://www.outreach.washington.edu/ext/certificates/aoa/aoa_crs.asp
> damorgan_at_x.washington.edu
> (replace 'x' with a 'u' to reply)
>
Received on Wed Nov 26 2003 - 23:12:33 CST

Original text of this message

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