Results 1 to 6 of 6
  1. #1
    Mehbastan is offline Novice
    Windows XP Access 2003
    Join Date
    Aug 2009
    Posts
    4

    Due dates

    Hi everyone.
    I really need your help. I am fairly new with MS Access and have made a database that holds my Customers info. One of the field in my database is ContractDueDate which holds the YEAR that customer's Contract are due for renewal. i.e 2009 (Days & Months are not important)
    I would like to get a report of those contract that are either due or going to be soon up for renewal a year ahead of time.
    What should I write in the Criteria field of the query?
    I would really appreciate your answer.
    Thanks

  2. #2
    dcrake's Avatar
    dcrake is offline Competent Performer
    Windows XP Access 2003
    Join Date
    Aug 2009
    Posts
    435
    <=Year(Date()+1)

    This is adding one year to todays year element then asking to show all those that are equal to or less than this value. In other words <=2010.

    You will have to include another clause that only brings up the ones that are outstanding.

    David

  3. #3
    Mehbastan is offline Novice
    Windows XP Access 2003
    Join Date
    Aug 2009
    Posts
    4
    I have 2 contracts one was due 07/2009 and the other is due on 08/2010
    The query must bring up both since one is past renewal by a month and should have been renewed the other is due in a year.
    The <=Year(Date()+1 does not bring up either one why?

  4. #4
    dcrake's Avatar
    dcrake is offline Competent Performer
    Windows XP Access 2003
    Join Date
    Aug 2009
    Posts
    435
    You originally said months and days were not important however you stated month and year in your last thread?

    What are you actually storing in the table?

  5. #5
    Mehbastan is offline Novice
    Windows XP Access 2003
    Join Date
    Aug 2009
    Posts
    4
    I'd like to have the field as YYYY only but I can not make the field accept Year only, how is that possible without putting a fake month in there?

  6. #6
    Mehbastan is offline Novice
    Windows XP Access 2003
    Join Date
    Aug 2009
    Posts
    4
    I Found the answer Thanks. I made the ContractDuedate into a Numeric Field and added
    <=Year(Date()) to the criteria which brings up the right customer every time.
    Thanks for your help

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

Similar Threads

  1. Calculating Dates
    By AJ0424 in forum Programming
    Replies: 1
    Last Post: 07-14-2009, 08:29 AM
  2. Fortnightly Dates
    By san-ron in forum Programming
    Replies: 3
    Last Post: 04-14-2009, 12:19 PM
  3. Exracting Dates
    By Elizabeth in forum Access
    Replies: 2
    Last Post: 04-02-2009, 11:26 AM
  4. Searching Dates
    By knightjp in forum Database Design
    Replies: 2
    Last Post: 08-16-2008, 11:39 PM
  5. Help with Searching Dates
    By rededdie in forum Access
    Replies: 1
    Last Post: 11-02-2007, 08:34 AM

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