R-00752-43975-33209-32622-59517-55856-49839-03222 tcl slt th3 src
The sqlite3_wal_hook() function is used to register a callback that is invoked each time data is committed to a database in wal mode.
/* IMP: R-00752-43975 */
# EVIDENCE-OF: R-00752-43975 The sqlite3_wal_hook() function is used to # register a callback that is invoked each time data is committed to a # database in wal mode.
R-65366-15139-04842-55947-24968-22096-64628-38309 tcl slt th3 src
The callback is invoked by SQLite after the commit has taken place and the associated write-lock on the database released
/* IMP: R-65366-15139 */
# EVIDENCE-OF: R-65366-15139 The callback is invoked by SQLite after the # commit has taken place and the associated write-lock on the database # released
R-52629-38967-65267-07230-17348-21667-50787-63164 tcl slt th3 src
The first parameter passed to the callback function when it is invoked is a copy of the third parameter passed to sqlite3_wal_hook() when registering the callback.
/* IMP: R-52629-38967 */
# EVIDENCE-OF: R-52629-38967 The first parameter passed to the callback # function when it is invoked is a copy of the third parameter passed to # sqlite3_wal_hook() when registering the callback.
R-23378-42536-56340-49562-54695-41894-41223-62715 tcl slt th3 src
The second is a copy of the database handle.
/* IMP: R-23378-42536 */
# EVIDENCE-OF: R-23378-42536 The second is a copy of the database # handle.
R-44294-52863-08300-09780-12014-19647-27880-25111 tcl slt th3 src
The third parameter is the name of the database that was written to - either "main" or the name of an ATTACH-ed database.
/* IMP: R-44294-52863 */
# EVIDENCE-OF: R-44294-52863 The third parameter is the name of the # database that was written to - either "main" or the name of an # ATTACH-ed database.
R-18913-19355-04042-04396-26693-02137-35105-64598 tcl slt th3 src
The fourth parameter is the number of pages currently in the write-ahead log file, including those that were just committed.
/* IMP: R-18913-19355 */
# EVIDENCE-OF: R-18913-19355 The fourth parameter is the number of pages # currently in the write-ahead log file, including those that were just # committed.
R-14034-00929-27099-16044-59671-40921-25544-35067 tcl slt th3 src
If an error code is returned, that error will propagate back up through the SQLite code base to cause the statement that provoked the callback to report an error, though the commit will have still occurred.
/* IMP: R-14034-00929 */
# EVIDENCE-OF: R-14034-00929 If an error code is returned, that error # will propagate back up through the SQLite code base to cause the # statement that provoked the callback to report an error, though the # commit will have still occurred.
R-10466-53920-46827-22051-27556-17000-33700-37865 tcl slt th3 src
Calling sqlite3_wal_hook() replaces any previously registered write-ahead log callback.
/* IMP: R-10466-53920 */
# EVIDENCE-OF: R-10466-53920 Calling sqlite3_wal_hook() replaces any # previously registered write-ahead log callback.
R-57445-43425-22232-12533-21797-53023-32757-29365 tcl slt th3 src
Note that the sqlite3_wal_autocheckpoint() interface and the wal_autocheckpoint pragma both invoke sqlite3_wal_hook() and will overwrite any prior sqlite3_wal_hook() settings.
/* IMP: R-57445-43425 */
# EVIDENCE-OF: R-57445-43425 Note that the sqlite3_wal_autocheckpoint() # interface and the wal_autocheckpoint pragma both invoke # sqlite3_wal_hook() and will overwrite any prior sqlite3_wal_hook() # settings.