>Hi,
>
>I wonder would anybody have any suggestions as to the best approach for creating an Audit Trail in a VFP6 program using free tables.
>I need to show new records, deleted records and old and new values of any records changed. The data relates to individual tickets with multiple records and the overall value of the changes needs to be calculated.
>Currently, I thinking along the lines of taken a snapshot of the data into a temporary table when a form is opened for editing and then comparing the live data with the snapshot on closing the form.
>Is this a good approach to take and is there any easy way to compare the tables, preferable using SQL.
>
>Thanks,
>Niall
You can use data buffering on free tables. You could use OLDVAL() to check the existing values of fields and compare that to your field directly to see the differences. You could also use CURVAL() to see if the field has been changed by someone else while you've been using the data.