Add other columns to Select Distinct Query

G

Guest

My Database has a table called ALLGPSData with the following
Fields..ID(PK,Autonumber), TXDate(transmission Date), TXTime(Transmission
Time), PTT(A Number indicating which Collar's Serial Number the record is
referring to), FixNo(the number in sequence from 1 to whatever that shows the
"how-manyeth" transmission that record is for that PTT on that transmission
day) Fix Status (Good or Bad), FixDate (the date when a position was Fixed),
FixTime (the time in the day when the position was fixed) Langitude, Latitude.

There are about 51492 records. Each record can have the same collar on the
same fixday and on the same fixtime and same tranmissionDate. The way that
they are differentiated from each other is through the transmission time.

I need to filter this long table so that I get one record for each collar
for each TX day.

What I have done is made an SQL like this...
SELECT DISTINCT ALLGPSData.PTT, ALLGPSData.FixDate
FROM AllGPS.Data;

From that above, I can see I have 3526 unique records.

Now, how do I add on to that all of the other relavent columns that I want.
I want to end up with PTT, FixStatus, FixDate, FixTime, Longitude, Latitude.

Any help on this would be so great and thanks in advance.

Eskimo
 
A

Allen Browne

Save the query you already have.

Now create another query. Add the AllGPSData table, and also add the query
you just saved.

In the upper pane of query design, drag AllGPSData.PTT onto Query1.PTT. Then
drag AllGPSData.FixDate onto Query1.FixDate. You should now have 2 lines
joining the 2 "tables" in the upper pane of query design.

Drag all the fields you want to see in the design grid.

(It may be more complex than that if there are Nulls in PTT or FixDate.)
 
G

Guest

Thanks allen,

your note in brackets explains everything. I am going to have to approach
the whole table and query from a different angle. There are too many null
values in the table, not just in the two fields, but in all fields.

I'll post in a new question what I am trying to do.

Thanks,

Eskimo
 

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