Jun 19, 2003 #1 Rmcta Technical User Nov 1, 2002 478 US I need to count how many records I have per hour. Example of my time field: 5:26:46 PM 12:38:28 PM 10:38:16 AM How do I do that? I need to know how many record I have from 6 to 8 am and then from 8 to 9 am ..and so on. Thank you very much
I need to count how many records I have per hour. Example of my time field: 5:26:46 PM 12:38:28 PM 10:38:16 AM How do I do that? I need to know how many record I have from 6 to 8 am and then from 8 to 9 am ..and so on. Thank you very much
Jun 19, 2003 1 #2 mpastore Programmer Mar 12, 2003 568 US I assume you have a date/time field: select hour([mydatetime]),count(*) from mytable group by hour([mydatetime]) Note: hours after 12PM will be in military format, e.g. 10PM is 22, etc. Mike Pastore Hats off to (Roy) Harper Upvote 0 Downvote
I assume you have a date/time field: select hour([mydatetime]),count(*) from mytable group by hour([mydatetime]) Note: hours after 12PM will be in military format, e.g. 10PM is 22, etc. Mike Pastore Hats off to (Roy) Harper
Jun 19, 2003 Thread starter #3 Rmcta Technical User Nov 1, 2002 478 US You are GREAT! Thank you very, very much Upvote 0 Downvote