Results 1 to 2 of 2
  1. #1
    shootnow is offline Novice
    Windows Vista Access 2007
    Join Date
    Aug 2011
    Posts
    1

    Count how many records hourly?


    Have a simple table with date, time, alarm.
    Want to make query to count how many alarms in table every hour daily. If none then just show 0 for that hour. Time is formatted like 11:31:14.8
    Any help.

  2. #2
    June7's Avatar
    June7 is online now VIP
    Windows XP Access 2010 32bit
    Join Date
    May 2011
    Location
    The Great Land
    Posts
    52,929
    Try:
    SELECT DateEnter, Hour([TimeEnter]) AS Hours, Count(TimeEnter) AS CountOfTimeEnter
    FROM Table1
    GROUP BY DateEnter, Hour([TimeEnter]);

    However, if there is no data for any hour, nothing will show for that hour.
    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.

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

Similar Threads

  1. count records, add boxes
    By Mclaren in forum Reports
    Replies: 2
    Last Post: 04-28-2011, 03:27 AM
  2. Count Records
    By Cheshire101 in forum Access
    Replies: 1
    Last Post: 11-30-2010, 03:02 PM
  3. Is it possible for me to count my records? how?
    By radicrains in forum Queries
    Replies: 4
    Last Post: 10-28-2010, 05:28 AM
  4. Count of records
    By Aston in forum Access
    Replies: 2
    Last Post: 03-30-2010, 05:20 AM
  5. Count of records
    By Bruce in forum Forms
    Replies: 3
    Last Post: 03-22-2010, 01:30 PM

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