{"action":"created","issue":{"url":"https://api.github.com/repos/ccgus/fmdb/issues/342","labels_url":"https://api.github.com/repos/ccgus/fmdb/issues/342/labels{/name}","comments_url":"https://api.github.com/repos/ccgus/fmdb/issues/342/comments","events_url":"https://api.github.com/repos/ccgus/fmdb/issues/342/events","html_url":"https://github.com/ccgus/fmdb/issues/342","id":56626978,"number":342,"title":"FMDB execute update freeze the app","user":{"login":"svetlanama","id":1378991,"avatar_url":"https://avatars.githubusercontent.com/u/1378991?v=3","gravatar_id":"","url":"https://api.github.com/users/svetlanama","html_url":"https://github.com/svetlanama","followers_url":"https://api.github.com/users/svetlanama/followers","following_url":"https://api.github.com/users/svetlanama/following{/other_user}","gists_url":"https://api.github.com/users/svetlanama/gists{/gist_id}","starred_url":"https://api.github.com/users/svetlanama/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/svetlanama/subscriptions","organizations_url":"https://api.github.com/users/svetlanama/orgs","repos_url":"https://api.github.com/users/svetlanama/repos","events_url":"https://api.github.com/users/svetlanama/events{/privacy}","received_events_url":"https://api.github.com/users/svetlanama/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"milestone":null,"comments":1,"created_at":"2015-02-05T04:44:22Z","updated_at":"2015-02-05T17:46:14Z","closed_at":null,"body":"I am using FMDatabaseQueue to have the ability work with fmdb using GCD.\r\nBut GCD does not help.\r\n\r\nWhen I try to perform any execute update query several times in one moment I got freeze of application.\r\n\r\nTo improve the performance I done \r\n - complex query to reduce the number of queries \r\n - use begin and commit transaction \r\n - use setShouldCacheStatements\r\n But NOTHING help\r\n\r\nHere is some example of code\r\nfunc complexQuery(sqlQuery: String) -> Bool {\r\n        \r\n        var result = false\r\n        self.databaseQueue.inDatabase() {\r\n            database in\r\n\r\n            database.setShouldCacheStatements(true)\r\n            database.beginTransaction()\r\n            result = database.executeStatements(sqlQuery)\r\n            database.commit()\r\n}\r\n\r\nCould you help me what I am doing wrong?\r\n\r\nThanks!"},"comment":{"url":"https://api.github.com/repos/ccgus/fmdb/issues/comments/73091701","html_url":"https://github.com/ccgus/fmdb/issues/342#issuecomment-73091701","issue_url":"https://api.github.com/repos/ccgus/fmdb/issues/342","id":73091701,"user":{"login":"ccgus","id":60178,"avatar_url":"https://avatars.githubusercontent.com/u/60178?v=3","gravatar_id":"","url":"https://api.github.com/users/ccgus","html_url":"https://github.com/ccgus","followers_url":"https://api.github.com/users/ccgus/followers","following_url":"https://api.github.com/users/ccgus/following{/other_user}","gists_url":"https://api.github.com/users/ccgus/gists{/gist_id}","starred_url":"https://api.github.com/users/ccgus/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/ccgus/subscriptions","organizations_url":"https://api.github.com/users/ccgus/orgs","repos_url":"https://api.github.com/users/ccgus/repos","events_url":"https://api.github.com/users/ccgus/events{/privacy}","received_events_url":"https://api.github.com/users/ccgus/received_events","type":"User","site_admin":false},"created_at":"2015-02-05T17:46:14Z","updated_at":"2015-02-05T17:46:14Z","body":"Can you paste a backtrace of everything that's going on when the app is frozen?\r\n\r\n'bt all' in lldb will print them out.\r\n\r\n-gus\r\n"}}