The database log (4D Server Log)
The 4D Server Log file can be accessed from 4D Server File menu. The log file keeps a record of all transactions performed by the database since the last backup. The database log is stored in a file with 4DL extension (e.g. ABC_CurrencyDatafile.4DL).
Accessing the database Log File
You can access the log file from the File menu of 4D Server.
Every time 4D performs a backup the log file becomes empty. The log file keeps the changes (additions, modification, deletion) to every table and field of the database.
Checking the log
The above log file shows transactions log of what changes and modifications were done on the data. You could verify the log file for checking if any modifications or deletions were performed. The log file is managed by 4D database engine. Every change to the data will be recorded in the log, even if the change has been done programmatically.
Rollback
Rollback is a database level "Undo". You can go back in time to any transaction that you wish. However, this is very advanced feature and you should know what you are doing before using this feature. The rollback feature is usefull to undo an accidential deletion or modification of important records. The rollback will restore the last backup and start implementing the changes in the log one by one until it reaches the point of rollback.
Rolling back
In the above log file we notice that the last 4 transactions are "Delete" transactions. We could undo the deletions by selecting the line 309 and the pressing Rollback. Before performing a rollback, make sure that all users are signed out and quit 4D client. This action can not be done while users are using the system.
Once you click OK, you cannot undo this. The system will undo the deleted records by loading the last backup and implementing all the changes until it reaches the point of undo. This is a very powerful feature but must be used only with extra caution.