470,833 Members | 1,985 Online
Bytes | Developer Community
New Post

Home Posts Topics Members FAQ

Post your question to a community of 470,833 developers. It's quick & easy.

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.

Similar topics

2 posts views Thread by kevin parks | last post: by
26 posts views Thread by Agoston Bejo | last post: by
6 posts views Thread by Bob Stearns | last post: by
4 posts views Thread by bwmiller16 | last post: by
7 posts views Thread by Brian Keating | last post: by
10 posts views Thread by Laurence | last post: by
2 posts views Thread by pstachy | last post: by
By using this site, you agree to our Privacy Policy and Terms of Use.