Enjoy an ad free experience by logging in. Not a member yet? Register.
Results 1 to 2 of 2
Thread: Creating A History
08-21-2005, 12:37 AM #1
- Join Date
- Apr 2005
- Thanked 0 Times in 0 Posts
Creating A History
I was wondering if anyone knows how to create a history of something. For example, a Client. I want to create a history of changes that were made to a client record. If someone changes his address or phone, etc. How do I record the changes that are made? Any ideas or suggestions would be greatly apprecieated.
08-22-2005, 02:52 AM #2
- Join Date
- Aug 2002
- Thanked 2 Times in 2 Posts
Well you seem to be going further than I ususally do. But you asked for any ideas and suggestions.
I often add a few record-tracking fields to the bottom of most tables. And then whenever code in a Web page adds or edits a record I have it call a function something like this:
' Set rec tracking var.
Call SetRecTrack(objRS, "Cust")
Function SetRecTrack(pobjRS, pstrTablePrefix)
' Purpose: Set rec tracking flds.
' Set var.
pobjRS(pstrTablePrefix & "EnterUserID") = Session("UserID")
pobjRS(pstrTablePrefix & "EnterUserLevel") = Session("UserLevel")
pobjRS(pstrTablePrefix & "EnterIPAddr") = Request.ServerVariables("REMOTE_ADDR")
pobjRS(pstrTablePrefix & "EnterDt") = mvarOrgCurDt
pobjRS(pstrTablePrefix & "EnterTime") = mvarOrgCurTimeExclSec