470,833 Members | 1,985 Online

# UNIQUE ?

Hi all

I hope I can explain what I am trying to do here....
I am trying to create a statement where it will return the UNIQUE values
from a table, I think its the UNIQUE statment.
So a table may have 60 entries, 20 of them are X, 20 Y and 20 Z
I want it to return only X,Y,Z e.g. 3 returned entries.

How do I do this?

Brian

Jul 20 '05 #1
4 1264
"Brian" <br***@nrwp.co.uk> wrote in message
news:XDBnc.838\$Ne7.815@newsfe1-win...
I hope I can explain what I am trying to do here....
I am trying to create a statement where it will return the UNIQUE values
from a table, I think its the UNIQUE statment.
So a table may have 60 entries, 20 of them are X, 20 Y and 20 Z
I want it to return only X,Y,Z e.g. 3 returned entries.

How do I do this?

select distinct value
from tablename;

Note this one too

select count(distinct value)
from tablename;
Jul 20 '05 #2
"Brian" <br***@nrwp.co.uk> wrote in message
news:XDBnc.838\$Ne7.815@newsfe1-win...
I hope I can explain what I am trying to do here....
I am trying to create a statement where it will return the UNIQUE values
from a table, I think its the UNIQUE statment.
So a table may have 60 entries, 20 of them are X, 20 Y and 20 Z
I want it to return only X,Y,Z e.g. 3 returned entries.

How do I do this?

select distinct value
from tablename;

Note this one too

select count(distinct value)
from tablename;
Jul 20 '05 #3
Thats the one !!! Thanks :)
I hope I can explain what I am trying to do here....
I am trying to create a statement where it will return the UNIQUE values
from a table, I think its the UNIQUE statment.
So a table may have 60 entries, 20 of them are X, 20 Y and 20 Z
I want it to return only X,Y,Z e.g. 3 returned entries.

How do I do this?

select distinct value
from tablename;

Note this one too

select count(distinct value)
from tablename;

Jul 20 '05 #4
Thats the one !!! Thanks :)
I hope I can explain what I am trying to do here....
I am trying to create a statement where it will return the UNIQUE values
from a table, I think its the UNIQUE statment.
So a table may have 60 entries, 20 of them are X, 20 Y and 20 Z
I want it to return only X,Y,Z e.g. 3 returned entries.

How do I do this?

select distinct value
from tablename;

Note this one too

select count(distinct value)
from tablename;

Jul 20 '05 #5

### This discussion thread is closed

Replies have been disabled for this discussion.