fix enabling foreign keys in sqlite

This commit is contained in:
Martin Brodbeck 2018-07-28 14:16:02 +02:00
parent 940688edd5
commit 9c56ec55a5
1 changed files with 3 additions and 1 deletions

View File

@ -107,7 +107,9 @@ void Database::init()
if (errCode) {
throw std::runtime_error("Could not open database file.");
}
sqlite3_db_config(db_, SQLITE_DBCONFIG_ENABLE_FKEY);
// sqlite3_db_config(db_, SQLITE_DBCONFIG_ENABLE_FKEY);
exec("PRAGMA foreign_keys = ON;");
int version = getVersion();