Link to home
Start Free TrialLog in
Avatar of SheriAMorgan
SheriAMorganFlag for United States of America

asked on

Calculation of dates within the same column, Access 2010

I need to be able to calculate the difference between two dates within the same column as shown below. I need the results to be returned as a number so that I can show instances where it took longer than 7 days to go from one ID to another.
Example.xlsx
ASKER CERTIFIED SOLUTION
Avatar of John Tsioumpris
John Tsioumpris
Flag of Greece image

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
Using a domain function in a query is a very expensive proposition.  The suggested expression will not work if there are multiple entries for a single day.  

If the data is input in order, you could calculate the difference as each new record is entered.  However, this would be a problem in a very busy application with multiple simultaneous users adding records.  It would also be a problem if a mistake was made and the data was entered out of order.  There must be some other column that you are not telling us about that defines a set of data.

A report is a better place to calculate the difference or using a recordset to loop through all records.
Multiple Entries For a single day will result to 0 days difference which is normal...there was not indication that there was need for time difference....