Delphi & C++ Builder components library
and Software development
 
 
 

DB Track components - automatize log of changes in DB

Do you have database application and need to log changes of records in some tables?
Use DB Track tool and you can add this function to your application without line of code.


DB Track tool consists of two components:

  • TrackRecTarget - defines target (log) table and fields where tracked information is saved, target table can be any descendant of TDataset (e.g. ADOTable, AQOQuery, BDETable ...)
    there must be one component for each log table in application (usually only one log table is used)
  • TrackRecSource - defines tracked table, fields and events, tracked table can be any descendant of TDataset
    there must be one component for each tracked table in application, each TrackRecSource is connected to TrackRecTarget

How to use DB Track tool:

  • in your database - create new table where log records will be saved, there should be defined fields for information about DateTime of changes, User, Action (edit, insert, delete), TableName, KeyValue of records and Changes
  • in your application - add any dataset connected to this table
  • add new component TrackRecTarget, select TargetDataSet and open design time dialog (dblclick on component), select names of fields in log table for each type of saved information
  • add new component TrackRecSource, select TrackRecTarget (target of log records), select TrackedDataSet, open design time dialog (dblclick on component) and select list of field for tracking, key field(s) and formatting string, then select tracking events and set table name
  • repeat last point for each table which should be tracked

Open documentation page.

Go back