While running iPhone App, I am getting message in console: "sqlite Prepare failed :out of memory"
What should I do to resolve it?
Please Help and Suggest.
Thanks.开发者_JAVA百科
What should I do to resolve it?
Provide more clues.
• Core Data or SQLite directly?
• Failing on device or simulator?
• backtrace of failure point?
More likely than not you are specifying a query that uses some kind of ordering that is causing SQLite to attempt to allocate a massive amount of memory to apply the ordering. In particular, it is likely trying to load the entire contents of the database into memory at once to apply the ordering.
I.e. your query is grossly inefficient.
(Which indicates that you are likely using SQLite directly and begs the question "Why not Core Data?")
精彩评论