So whenever COMMIT is issued by the transaction or if the ULC becomes full, Sybase sends the modified pages into the database's transaction log.
At that time, we can say, that transaction log is more important as the database itself. Every committed transaction is saved in the log first. The data file can be not modified at all! Let's analyze, what happens when user modifies some data:
- data is read form the disk into the buffer
- user transaction begins
- transaction data modifications are done and stored in ULC
- finally, the transaction issues the COMMIT
- data from ULC is sent to transaction log
- when the 'save on disk' operation finishes the user application can continue, as at that moment we are sure, that the transaction is fully stored on the disk, data modification is also done in memory buffer, where the "up to date" pages are stored
- ...
- at some moment a CHECKPOINT is issued
- CHECKPOINT synchronizes the data from buffer cache to disk