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: Daniel Morgan <damorgan_at_x.washington.edu>
Date: Wed, 26 Nov 2003 08:37:20 -0800
Message-ID: <1069864672.725596@yasure>


Prince Of Thieves wrote:

> Problem is....I'm not an Oracle guru. I just know the basic SQL and the
> following are unknown to me so I hope someone can explain what they do:
>
> COUNT (*)>1
>
> How does this work?
>
> SELECT REPLACE (STYLECODE, ' ','')
>
> What does this line do?
>
> Thanks.
>

It would have been really helpful if you had included the actual SQL statement instead of making people guess. But since you didn't all you get are guesses.

The SQL statement you are working with is in the following format:

SELECT column, COUNT(*)
FROM sometable
GROUP BY column
HAVING COUNT(*) > 1; Which means don't return rows where the count is less than 2.

The second statement replaces any double spaces it finds ' ' with single spaces ' '.

And as Jan suggests ... you need to get a book for starters and explore local universities and colleges for a class on SQL.

-- 
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 - 10:37:20 CST

Original text of this message

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