[AccessD] Get top dates from table.

Gustav Brock Gustav at cactus.dk
Tue Nov 16 01:01:33 CST 2010


Hi Darryl

>From the example data all that is needed is a Group By on the date field and a select of Min of the rate.
However, your question mentions a date range ... not seen here?

/gustav


>>> Darryl.Collins at iag.com.au 16-11-2010 06:00 >>>

Hi guys and gals.

I have a friend at work trying something crafty.  He has a table which consists of many dates.  he wants a query that returns the top date from each possible date range.  A simple example below.

1-Nov-2010  1
1-Nov-2010  2
1-Nov-2010  3
1-Nov-2010  4
2-Nov-2010  1
2-Nov-2010  2
2-Nov-2010  3
3-Nov-2010  1
4-Nov-2010  1
4-Nov-2010  2
4-Nov-2010  3
5-Nov-2010  1

Should return

1-Nov-2010  1
2-Nov-2010  1
3-Nov-2010  1
4-Nov-2010  1
5-Nov-2010  1

Having a senior's moment with this.  Any pointers?  Annoyingly I already know how to do it in Excel :)

cheers
Darryl.






More information about the AccessD mailing list