database.enableDefensive(active)


  • active <boolean> 是否设置防御标志。

    ¥active <boolean> Whether to set the defensive flag.

启用或禁用防御标志。启用防御标志后,允许普通 SQL 故意损坏数据库文件的语言特性将被禁用。有关详细信息,请参阅 SQLite 文档中的 SQLITE_DBCONFIG_DEFENSIVE

¥Enables or disables the defensive flag. When the defensive flag is active, language features that allow ordinary SQL to deliberately corrupt the database file are disabled. See SQLITE_DBCONFIG_DEFENSIVE in the SQLite documentation for details.