How do I unlock a SQLite database?

前端 未结 30 1738
栀梦
栀梦 2020-11-22 15:56
sqlite> DELETE FROM mails WHERE (`id` = 71);
SQL error: database is locked

How do I unlock the database so this will work?

30条回答
  •  感情败类
    2020-11-22 16:38

    If you want to remove a "database is locked" error then follow these steps:

    1. Copy your database file to some other location.
    2. Replace the database with the copied database. This will dereference all processes which were accessing your database file.

提交回复
热议问题