View Full Version : use query to find first record


TimTDP
03-01-2010, 06:39 PM
I have a database that includes an itinerary.
I need to build a query that returns the first record in the itinerary for each guardian.
I have attached a sample database which has two tables
tblData = the data
tblResult = this is what I want the query to return

How do I build such a query?

pbaldy
03-01-2010, 08:04 PM
I don't quite understand why some records are chosen, but see if this helps:

http://www.baldyweb.com/LastValue.htm

gemma-the-husky
03-02-2010, 01:11 AM
how do you define the first item - is there a sequence number, or an earliest date/time.

sort ascending on that field, and the top row will be the first item.