General discussion

  • Creator
    Topic
  • #2080590

    Running a Date/Time Query

    Locked

    by layland ·

    I have Access 2000 and I need to creat a query at will look for all records for a week.
    Example: Say 05/22/00 thru 05/28/00.
    What is the criteria for that?
    (The date/time feild looks like this:
    5/23/00 1:51 AM)

All Comments

  • Author
    Replies
    • #3895318

      Running a Date/Time Query

      by larry h. ·

      In reply to Running a Date/Time Query

      In the Query Grid’s criteria row for the date in question type:
      BETWEEN #5/22/00# AND #5/28/00#

      That will select from midnight to midnight of the respective days.

    • #3894301

      Running a Date/Time Query

      by leehlc ·

      In reply to Running a Date/Time Query

      If you want to be prompted for the dates everytime you run the query(instead of having them hard-coded as 05/22/00 and 05/28/00 or whatever: Type the following in the criteria for your date/time field.
      Between [Enter start date] AND [Enter end date]

      This will prompt you each time you run the query. You can put whatever text you want in the square brackets. You will not have to enter the time portion, it will assume midnight to midnight.

Viewing 1 reply thread