Results 1 to 4 of 4
  1. #1
    Star Lounger
    Join Date
    Apr 2001
    Location
    Oklahoma City, Oklahoma, USA
    Posts
    54
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Date question from query (A2K)

    I have a number of queries that I need to run before the end of the month that update the start date in a database based on the end date and the length. What I need to do is to automatically have the query look at the current month and select from the EndDate field all records from the last day of the next month. Now I am using Date()+# where # is the number of days between the day done and the end of the month, can this be coded?

  2. #2
    Plutonium Lounger
    Join Date
    Dec 2000
    Location
    Sacramento, California, USA
    Posts
    16,775
    Thanks
    0
    Thanked 1 Time in 1 Post

    Re: Date question from query (A2K)

    Have you looked at the DateAdd function? It isn't clear to me which part of your problem you need help on--determining the number of days betweeh the day done (what does that mean, anyhow?) and the end of the month or creating the update query.
    Charlotte

  3. #3
    2 Star Lounger
    Join Date
    Dec 2000
    Posts
    120
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Re: Date question from query (A2K)

    Just add this to the criteria for EndDate to return records for the last day of the next month.

    ateSerial(Year(Date()),Month(Date())+2,0)

  4. #4
    Star Lounger
    Join Date
    Apr 2001
    Location
    Oklahoma City, Oklahoma, USA
    Posts
    54
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Re: Date question from query (A2K)

    Thnks

    It worked.

Posting Permissions

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