Results 1 to 3 of 3
  1. #1
    MFS is offline Competent Performer
    Windows 7 32bit Access 2010 32bit
    Join Date
    Mar 2009
    Location
    Ohio
    Posts
    235

    Calculate Field Results

    I have a query that shows . . .


    Employee_Clock_Number
    Overtime_Hours
    Department
    Name_Last
    Name_First

    What I am trying to accomplish in either the same query or a separate query to show how many employees work for each department. (By counting each unique Clock_Number or some other means, it really doesn't matter)

    I hope someone can help me.

    Speck

  2. #2
    June7's Avatar
    June7 is offline VIP
    Windows 7 64bit Access 2010 32bit
    Join Date
    May 2011
    Location
    The Great Land
    Posts
    53,770
    Build a query that selects DISTINCT Department and Employee_Clock_Number.

    Then use that query as source for a GROUP BY that counts the records grouped by Department.

    An all-in-one SQL could be like:

    SELECT Department, Count(*) FROM (SELECT DISTINCT Employee_Clock_Number, Department FROM table) AS Query1 GROUP BY Department;
    How to attach file: http://www.accessforums.net/showthread.php?t=70301 To provide db: copy, remove confidential data, run compact & repair, zip w/Windows Compression.

  3. #3
    MFS is offline Competent Performer
    Windows 7 32bit Access 2010 32bit
    Join Date
    Mar 2009
    Location
    Ohio
    Posts
    235
    Wow!! That works perfectly.
    Thank You June7

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

Similar Threads

  1. Replies: 2
    Last Post: 10-20-2014, 07:59 AM
  2. How to calculate and Update Field via VBA
    By rd.prasanna in forum Programming
    Replies: 2
    Last Post: 09-05-2013, 04:05 PM
  3. Replies: 1
    Last Post: 02-05-2013, 12:15 PM
  4. How to calculate results from two tables ?
    By Nokia N93 in forum Access
    Replies: 1
    Last Post: 02-01-2013, 03:20 PM
  5. Replies: 5
    Last Post: 12-17-2010, 11:06 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