Check-in [fe57da72ab]
Not logged in
Overview

SHA1 Hash:fe57da72abef9d9003ac93f68699f74032fbe9bc
Date: 2009-09-19 17:58:56
User: drh
Comment:Make sure foreign key constraints are disabled when a new database connection is created.
Timelines: ancestors | descendants | both | trunk
Other Links: files | ZIP archive | manifest

Tags And Properties
Changes
[hide diffs]

Modified src/db.c from [cb27c96070] to [16bc22dd3c].

@@ -1143,10 +1143,11 @@
 ** database connection is first established.
 */
 LOCAL void db_connection_init(void){
   static int once = 1;
   if( once ){
+    sqlite3_exec(g.db, "PRAGMA foreign_keys=OFF;", 0, 0, 0);
     sqlite3_create_function(g.db, "print", -1, SQLITE_UTF8, 0,db_sql_print,0,0);
     sqlite3_create_function(
       g.db, "file_is_selected", 1, SQLITE_UTF8, 0, file_is_selected,0,0
     );
     if( g.fSqlTrace ){