Fmdb Executeupdate Drop Command Does Halt The App
I want to drop a table in my SQLite Database file named database.db. After using NSLog(@'i show up in the console'); [db executeUpdate:@'DROP TABLE IF EXISTS `article`;']; NSLog(@
Solution 1:
I had the same issue, and got it solved by calling closeOpenResultSets on the FMDB instance just before the update, just like TRD said (though I didn't have to close and reopen the database completely)
Solution 2:
I finally got rid of this nasty behaviour. I closed the database connection right before the drop query and reopened it immediately. If I have to guess I'd say that SELECT-Queries in earlier parts of my source code made the connection to be locked for DROP-statements. So closing the database connection and reopen it resets those locks. Hope this can help you @JLoewy.
Post a Comment for "Fmdb Executeupdate Drop Command Does Halt The App"