I think this is a really newbie type of question, basically down to me not understanding SQL syntax, but as that is one the the reasons I am designing this database, I'll ask away if that's alright.
I have a db with a table (TblEvents) that contains;
EventID ( pk autonumber)
EventType ( look-up to another table)
JobID (ditto)
EventTime (time), and a Notes field.
I want to find the latest EventType, EventTime, Notes for each job. Looking through the forum, I have cobbled together this;
SELECT T1.JobID, MAX(T1.EventTime) AS EventTime
FROM TblEvents AS T1
GROUP BY T1.JobID;
This gives me the latest event time for each JobID ~ but how do I include the other fields in the results? Any advice appreciated.
I have a db with a table (TblEvents) that contains;
EventID ( pk autonumber)
EventType ( look-up to another table)
JobID (ditto)
EventTime (time), and a Notes field.
I want to find the latest EventType, EventTime, Notes for each job. Looking through the forum, I have cobbled together this;
SELECT T1.JobID, MAX(T1.EventTime) AS EventTime
FROM TblEvents AS T1
GROUP BY T1.JobID;
This gives me the latest event time for each JobID ~ but how do I include the other fields in the results? Any advice appreciated.