I have a table with a lot of transactions (date, time, name of employee, transaction number, etc.). There are two rows of importance to me--The date and time of the transaction. For example:
Date--------------Time
1/4/2004----- 1/4/2004 9:05:00 AM
1/4/2004----- 1/4/2004 9:08:00 AM
1/4/2004----- 1/4/2004 9:10:00 AM
1/4/2004----- 1/4/2004 9:10:00 AM
1/4/2004----- 1/4/2004 10:31:00 AM
1/5/2004----- 1/5/2004 1:00:00 PM
1/5/2004----- 1/5/2004 1:01:00 PM
1/5/2004----- 1/5/2004 1:08:00 PM
1/5/2004----- 1/5/2004 3:00:00 PM
I wanted to count the difference between the 1st transaction and 2nd transaction, 2nd transaction and 3rd transaction, and so on for each specific date. However, I want to exclude any time between the transactions that is greater than 10 minutes (by entering >10 in criteria). So, for example, the time between 9:10 a.m. and 10:31 a.m. on 1/4/2004 does not show up on my query.
The expression I used was:
[FONT="]Delay: DateDiff("s",DMax("[TIME]","TableName","[DATE]=#" & [DATE] & "#
AND [TIME]<#" & [TIME] & "#"),[TIME])[/FONT]
However, there are two problems:
1. When I get the results for my query the time between 9:10 a.m. and 9:10 a.m. on 1/4/2004 comes up as 2 minutes, which is actually the time between 9:08 a.m. and 9:10 a.m. How can I fix this?
2. When I run a report I want to sum up the "Delay" times that are equal to less than 10 minutes each day. However, the results I get look like this:
--Date------------Time--------------Time Between Transaction
1/4/2004---- 1/4/2004 9:05:00 AM
1/4/2004---- 1/4/2004 9:08:00 AM---- 3
1/4/2004---- 1/4/2004 9:10:00 AM---- 2
etc., etc.,
But I want the totals to look like this:
--Date-----Time Between Transaction
1/4/2004---- 5
1/5/2004---- 8
Any help on these 2 problems? Thanks.
Date--------------Time
1/4/2004----- 1/4/2004 9:05:00 AM
1/4/2004----- 1/4/2004 9:08:00 AM
1/4/2004----- 1/4/2004 9:10:00 AM
1/4/2004----- 1/4/2004 9:10:00 AM
1/4/2004----- 1/4/2004 10:31:00 AM
1/5/2004----- 1/5/2004 1:00:00 PM
1/5/2004----- 1/5/2004 1:01:00 PM
1/5/2004----- 1/5/2004 1:08:00 PM
1/5/2004----- 1/5/2004 3:00:00 PM
I wanted to count the difference between the 1st transaction and 2nd transaction, 2nd transaction and 3rd transaction, and so on for each specific date. However, I want to exclude any time between the transactions that is greater than 10 minutes (by entering >10 in criteria). So, for example, the time between 9:10 a.m. and 10:31 a.m. on 1/4/2004 does not show up on my query.
The expression I used was:
[FONT="]Delay: DateDiff("s",DMax("[TIME]","TableName","[DATE]=#" & [DATE] & "#
AND [TIME]<#" & [TIME] & "#"),[TIME])[/FONT]
However, there are two problems:
1. When I get the results for my query the time between 9:10 a.m. and 9:10 a.m. on 1/4/2004 comes up as 2 minutes, which is actually the time between 9:08 a.m. and 9:10 a.m. How can I fix this?
2. When I run a report I want to sum up the "Delay" times that are equal to less than 10 minutes each day. However, the results I get look like this:
--Date------------Time--------------Time Between Transaction
1/4/2004---- 1/4/2004 9:05:00 AM
1/4/2004---- 1/4/2004 9:08:00 AM---- 3
1/4/2004---- 1/4/2004 9:10:00 AM---- 2
etc., etc.,
But I want the totals to look like this:
--Date-----Time Between Transaction
1/4/2004---- 5
1/5/2004---- 8
Any help on these 2 problems? Thanks.