Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations strongm on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Use updated info but retain history 1

Status
Not open for further replies.

PlsHlpKat

IS-IT--Management
Feb 20, 2003
49
US
I have an HR system in Microsoft Access, one table lists pay rates, merit increases, status changes etc. but I need only the current pay rate and information to show up on the reports and main form. As it stands right now the reports lists every pay rate and status change. I do need to keep a history of all.
 
Are you storing a timestamp of each action? Instead of updating the record each time the pay rate changes, you could insert a new record with a different timestamp. You can always access the latest one by using the MAX() method.

Code:
select MAX(<timeStamp>) from <myTable>
 
Yes I am inserting a new record for each change but I am not clear on what you mean by a time stamp, could you please explain?
 
Timestamp is a spesific point in time. So you can store the date and time that the new record was inserted and use the MAX() to retrieve the last one. Is it clearer?
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top