I'm building a database in Access 2007 that will be used to track lab usage at my job. I have a table that has the user ID, date of sign-in, time of sign-in, etc. Now I'm trying to build a query to count the number of sign-ins in a given hour. So here's what I have, and it's not working:
First field is my sign-in date field where the date = a given date. Second field is where I'm having trouble. Here's what I have in the field box:
8 AM:[Copy Of SignIn]![Sign_In_Time] Between #8:00:00 AM# And #8:59:59 AM#
I'm naming the field "8 AM" (it won't let me name it "8:00 AM" for some reason but that is a minor issue), and I'm trying to tell it I want all entries between 8:00 and 8:59. I haven't even gotten to the count part yet. But am I supposed to use Group By or what?? Either way, it won't let me enter that in the field box. It's telling me I'm using an invalid date value.
Can anyone help me?
EDIT: It finally let me enter that expression above, but it is giving me a count of 35 (which is all of them!), when I actually only have 1 entry for that time range.
Edited by jtphenom, 25 March 2011 - 12:01 PM.