SQLite Forum

What reading wal can result in `BusyError: database is locked`?
Login
I got the following error when I read the journal_mode (in python apsw).

```
    if c.execute('PRAGMA journal_mode;').fetchone()[0] != 'wal':
  File "src/cursor.c", line 1019, in APSWCursor_execute.sqlite3_prepare
  File "src/statementcache.c", line 386, in sqlite3_prepare
apsw.BusyError: BusyError: database is locked
```

Since I just read something from the database, why does it matter whether the database is locked or not? Thanks.