Results 1 to 4 of 4
  1. #1
    aquabp is offline Advanced Beginner
    Windows 8 Access 2013
    Join Date
    Apr 2015
    Posts
    69

    Evaluate Date in Table against current date.

    I have a table that uses a general date format, (Date and time). I am trying to break the table down in a report to show Past, Current and Future Dates by assigning a sort value to each group. I am using the following in a queryS1:[DateTime]<Date(),1). Using this I get dates that are less then the current date as planned. When I query DS3:[Date_Time]>Date(),3) I get future dates and the current date. When I use DS2[DateTime]=Date(),2) I get no values. To confirm there are current dates in the table. What am I missing?

  2. #2
    RuralGuy's Avatar
    RuralGuy is offline Administrator
    Windows 10 Access 2013 32bit
    Join Date
    Mar 2007
    Location
    8300' in the Colorado Rocky Mountains
    Posts
    12,922
    You may already know this but I thought I'd include a link that describes how a DateTime value is stored. https://support.microsoft.com/en-us/kb/130514
    You may not have any stored DateTime values that have a time value of midnight.

  3. #3
    aquabp is offline Advanced Beginner
    Windows 8 Access 2013
    Join Date
    Apr 2015
    Posts
    69
    Thanks RualGuy! I was able to use the article to solve the issue!! Thanks again!!

  4. #4
    RuralGuy's Avatar
    RuralGuy is offline Administrator
    Windows 10 Access 2013 32bit
    Join Date
    Mar 2007
    Location
    8300' in the Colorado Rocky Mountains
    Posts
    12,922
    You're most welcome and thanks for marking this thread as Solved.

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

Similar Threads

  1. Replies: 3
    Last Post: 05-10-2016, 11:51 AM
  2. Replies: 3
    Last Post: 03-02-2016, 09:39 AM
  3. Replies: 3
    Last Post: 02-16-2016, 05:02 PM
  4. Replies: 3
    Last Post: 08-21-2015, 08:14 AM
  5. Replies: 5
    Last Post: 04-03-2012, 07:24 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