Database change counter in WAL mode
Is there a reason SQLite doesn't bother to update the change counter of the main database file while in WAL mode? I'd like to be able to determine the "version" of the database after the connections have been closed. Is this in anyway possible?
Is there a reason SQLite doesn't ... update the change counter ... in WAL mode?
Yes. WAL mode does not use the change counter. And updating the change counter involves extra code, extra CPU cycles, and extra I/O. So SQLite is smaller and runs faster without WAL-mode change counter updates.