Results 1 to 6 of 6
  1. #1
    ERB is offline Novice
    Windows XP Access 2007
    Join Date
    Apr 2012
    Posts
    6

    Unhappy Help with isolating lastest date/time with MAX function or Latest or?

    I cant attached a screen shot so I will make a real simple mock up of the problem I am trying to solve asap .



    Table:

    Student_ID FN LN DateTaken

    1001 John Doe 2/16/2012 4:17:00 PM

    1001 John Doe 2/17/2012 4:18:00 PM

    1002 Jane Doe 1/18/2012 11:30:00 AM

    1002 Jane Doe 1/18/2012 2:30:00 PM


    My dilema is that I have student records with either mulptiple test dates or or test taken times. What I would like to do, is to reduce this down so that I only end up with those student records that have the lastest test date or time taken. I have tried the MAX and latest functions, is there a way to go about this that I am not seeing? I am using Access 2007 Below is an example of what I would like the above to look like.


    1001 John Doe 2/17/2012 4:18:00 PM

    1002 Jane Doe 1/18/2012 2:30:00 PM


    Thank you very much for any help or clues you guys can provide.

  2. #2
    alansidman's Avatar
    alansidman is offline Indifferent
    Windows 7 32bit Access 2007
    Join Date
    Apr 2010
    Location
    Steamboat Springs
    Posts
    2,536
    You will need an aggregate query. Look at this page and scroll down to Group By features.

    http://www.techonthenet.com/access/queries/index.php

    You will have to aggregate on the Student ID and if you need the name, then join it in a subsequent query with the Student Table.

  3. #3
    pbaldy's Avatar
    pbaldy is offline Who is John Galt?
    Windows XP Access 2007
    Join Date
    Feb 2010
    Location
    Nevada, USA
    Posts
    22,640
    Paul (wino moderator)
    MS Access MVP 2007-2019
    www.BaldyWeb.com

  4. #4
    ERB is offline Novice
    Windows XP Access 2007
    Join Date
    Apr 2012
    Posts
    6
    Wow thank you both very much. It was a big help! I finally got it to work. I am still testing to be sure, but it looks like it will do what I need it to. Saved me a lot of time and frustration. Thanks again!

  5. #5
    ERB is offline Novice
    Windows XP Access 2007
    Join Date
    Apr 2012
    Posts
    6
    how do I make this thread as solved? or is that done by the moderator?

  6. #6
    pbaldy's Avatar
    pbaldy is offline Who is John Galt?
    Windows XP Access 2007
    Join Date
    Feb 2010
    Location
    Nevada, USA
    Posts
    22,640
    Happy to help. You can mark it solved, via the "Thread Tools" link at the top of the thread.
    Paul (wino moderator)
    MS Access MVP 2007-2019
    www.BaldyWeb.com

Please reply to this thread with any new information or opinions.

Similar Threads

  1. Selecting Earliest and latest date
    By kstyles in forum Queries
    Replies: 10
    Last Post: 12-31-2010, 03:04 PM
  2. How do you get the latest date?
    By radicrains in forum Queries
    Replies: 6
    Last Post: 10-27-2010, 08:59 PM
  3. how can i get lastest date
    By Balen in forum Access
    Replies: 1
    Last Post: 08-09-2010, 01:22 PM
  4. Query for latest date? what am I doing wrong?
    By Overdive in forum Queries
    Replies: 1
    Last Post: 12-18-2009, 06:04 AM
  5. Latest Date Records
    By Rick West in forum Queries
    Replies: 1
    Last Post: 09-25-2009, 11:16 AM

Tags for this Thread

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
Other Forums: Microsoft Office Forums