Results 1 to 2 of 2

Thread: Access Question

  1. #1

    Thread Starter
    Addicted Member TheGoldenShogun's Avatar
    Join Date
    Mar 2001
    Location
    VA/MD... anywhere around the beltway
    Posts
    236

    Cool Access Question

    This is more of a Microsoft Access question but I figured this was the best place to post it.

    I'm creating a reporting database in Access with Forms that my company will be entering in Hotline information for. The Forms are easy and it doesn't have to be too professional, just four of us in the office are going to use it instead of using Excel spreadsheets.

    But my question is, I'm trying to print up a report based on a Query. The Query is going to display all Hotline calls that occured during the current month. I have a fldDate (Date/Time) field that will be checked and should have the equation of BETWEEN the first day of the month and the last day of the month. I'm having trouble with that. I can say BETWEEN #11/01/2001# AND #11/30/2001# but I can't seem to figure out how to build that dynamically, so that each month I just push the button to print the report and the report automatically figured out what month it is and prints out all Hotline calls within that month.

    Anybody got any ideas?


  2. #2
    Hyperactive Member
    Join Date
    Feb 2001
    Location
    Belgium/Antwerp
    Posts
    275
    Build this in acces:

    SELECT Table1.datum, Table1.zz, Month(Now())-Month([datum]) AS Expr1
    FROM Table1
    WHERE (((Month(Now())-Month([datum]))=0));

    caution: This will select also the current month from other years!

    Luc

Posting Permissions

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



Click Here to Expand Forum to Full Width