View Single Post
  #4 (permalink)  
Old June 17th, 2004, 08:50 PM
sal sal is offline
Friend of Wrox
Join Date: Oct 2003
Location: Clarksville, TN, USA.
Posts: 702
Thanks: 0
Thanked 0 Times in 0 Posts

On keeping changes by datte and user, it depends on how comlicated you want your life to be. You can use a default value for a field that sets to getdate() for entered date, a trigger for last update date and a default value of CURRENT_USER() in a field for enterd by, and in the same trigger you can set another field for last changed by. You must use distinct usernames for each individual who will be using the database and it would be best to use windows authentication (read about it in books on line) and use role based security for permission levels.

Or you could use a table that inserts a new record after every change on a table and do all the data adds / edits / deleted by stored procedure and then you can keep true history of how much your users change data for dumb reasons and you will be able to brag about how much you hate life because it will take you a long time to implement :(. Just kidding, if that is what you need, it does take a while and makes your database grow too large.

Reply With Quote