Comparing Rows in a Table

  • Thread starter Thread starter acal675177
  • Start date Start date
A

acal675177

I have a table that is collecting warehouse activity via timestamp. So
each time Tech 1 scans a package a time stamp and transaction number is
placed as a row in the table.

Activity ID (autonumber)
TECHID (text)
TimeStamp (date/time)
TimeDiff

I would like to update the field TimeDiff but determining the amount of
time between the previous transaction.

Transaction 1 happend at 12:00 PM
Transaction 2 happend at 1:00 PM TimeDiff is 1 hour


I do not know how to write this in a module for Microsoft Access 2002.

Help!!

Gee
 
First, you should not store a calculated value in a table. It wastes disc
space, takes more time, and is prone to be incorrect if anything that affects
the calculation changes.

Your calculations should be done when you want to present the results to a
user on a form or in a report.
 
Back
Top