Results 1 to 2 of 2
  1. #1
    sarahjh is offline Novice
    Windows 7 32bit Access 2010 32bit
    Join Date
    Apr 2012
    Posts
    1

    Use DMAX in query

    I am not knowledgeable in VBA or SQL. I've never used the function dmax before, though I've tried and cannot get the structure correct, and need help in using this in a query. In the table [event_history_view] are listed various events ([event_code]) associated with each claim_pk. Each event has a scheduled due date.



    From the table I want to get the event for each claim_pk that is furthest in the future. These are the tables and fields ([table].[field] ) I'm working with:

    [event_history_view].[claim_pk]
    [event_history_view].[event_code]
    [event_history_view].[current_sched_date]

    Each permutation I try results in an error. Can someone help me?

  2. #2
    pbaldy's Avatar
    pbaldy is offline Who is John Galt?
    Windows XP Access 2007
    Join Date
    Feb 2010
    Location
    Nevada, USA
    Posts
    22,640
    Would this work for you?

    http://www.baldyweb.com/LastValue.htm
    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. DMAX in VBA
    By Meanfish in forum Access
    Replies: 1
    Last Post: 11-03-2012, 11:06 AM
  2. Replies: 6
    Last Post: 07-24-2012, 03:02 PM
  3. How to use DMAX
    By tomneedshelp in forum Access
    Replies: 2
    Last Post: 03-01-2012, 07:22 AM
  4. Using Nz and Dmax
    By timmy in forum Programming
    Replies: 5
    Last Post: 07-04-2011, 06:42 AM
  5. append query: dlookup or dmax problem
    By jeffr27 in forum Queries
    Replies: 1
    Last Post: 05-10-2011, 09:25 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