Results 1 to 3 of 3
  1. #1
    Join Date
    Jan 2004
    Posts
    11

    Question Unanswered: Access 97 Query Help

    Hello -

    I've got a billing database that contains employee work information, ie. name, week end date worked, actual date worked, number of hours worked, date posted, and date extracted from the main database.

    I've got a query that shows me ALL the employee records that posted for the previous week. There are usually about 1000 records per week.

    I've got another query that flags when an employee posts hours more than 1 week late...sometimes it might even be months after they worked. There are usually about 50 late postings (records) per week.

    I've got criteria set in 2 fields along with an if statment to flag those late postings:

    Field: Week End Date
    Criteria: <[Enter Last Friday's Date mm/dd/yy]

    Field: Extract Date
    Criteria: >=[Enter Current Extract Date mm/dd/yy]

    LEO Correction: IIf([Week End Date]<[Extract Date],"Yes")...

    Here's my problem. If I add this IF statement to query #1, it flags ALL 1000 records as YES even if they weren't late postings. But I need to be able to see this information in a single query, rather than going back and forth. Is there a way to show all the records, but only flag the pertinent ones?

    While now new to access, I work with really simple queries and don't know a lot about sql statements.

    Thx!

  2. #2
    Join Date
    Nov 2003
    Posts
    1,487
    IIf([Week End Date]<[Extract Date] AND [Week End Date]>=lastFridaysDate,"Yes", "No")

  3. #3
    Join Date
    Jan 2004
    Posts
    11

    Smile Access 97 Query Help

    This is perfect - THANK YOU!!!

Posting Permissions

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