Oracle FAQ | Your Portal to the Oracle Knowledge Grid |
Home -> Community -> Usenet -> c.d.o.misc -> Re: Finding data with spaces in them.
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 ' '.
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 - 18:19:05 CST