Results 1 to 2 of 2

Thread: Date and Time

  1. #1
    Join Date
    Feb 2004

    Question Unanswered: Date and Time

    I have a field that tracks users log in and log out time. The field contains the date and the time from the Now() function. I need to run a query or code that will show all users that have been logged in greater than 30 minutes. When I try [Log In Time]<=Time()-30 it subtracts 30 days. How do i get it to subtract minutes?

  2. #2
    Join Date
    Nov 2004
    out on a limb
    Provided Answers: 59
    have a look at the datediff or dateadd functions
    or if you know your application is only going to be used within Access then you could take advantage of the way access/JET stores date time values. As you already know subtracting 1 from an Access/JET value gives one day so if you tell your query to look for a difference of 30/(24*60) that should give you the 30 minute window you are looking for....

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts