query trouble

Y

yew

Hello,

I have an access database with data that looks like this:

readname colour number height
AXG0019 red 6 183
AXG0019 red 6 182
AXG0016 pink 3 209
AXGHN93 green 2 56
AXGHN93 green 2 65

and want to write a query such that only rows with unique values in "readname
are reported. I tried to do this with SELECT DISTINCT but only returned th
readname column. How do I select distinct readnames, but include the other data
ie: I want the output for my madeup example to look like:

readname colour number height
AXG0019 red 6 183
AXG0016 pink 3 209
AXGHN93 green 2 56

Any help would be much appreciated.
Kind regards,
Yew :).
 
P

PieterLinden via AccessMonster.com

SELECT UniqueColor.readname, UniqueColor.colour, UniqueColor.number, First
(UniqueColor.height) AS FirstOfheight
FROM UniqueColor
GROUP BY UniqueColor.readname, UniqueColor.colour, UniqueColor.number;
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top