IBM MobileFirst 8.0: JSONStore initialization issue on iOS 13.1

401 views Asked by At

My app is working fine on iOS 12.4.1 It already has JSONStore with data inside. After updating to iOS 13.1 Beta 4, I got this error when trying to initialize JSONStore

{\n \"src\": \"initCollection\",\n \"err\": -1,\n \"msg\": \"PERSISTENT_STORE_FAILURE\",\n \"col\": \"globalData\",\n \"usr\": \"common\",\n \"doc\": {},\n \"res\": {}\n}

I've updated cordova-plugin-mfp and cordova-plugin-mfp-jsonstore yet it's still the same.

This is the code block

function(collections, successCallback, errorCallback, options) {

       return WL.JSONStore.init(collections, options)
           .then(successCallback)
           .fail(function() {
               WL.JSONStore.init(collections, options)
               .then(successCallback).
               fail(errorCallback);
           });

}

Below are the errors in XCode console log

error 13:43:10.039914 +0800 salesApp file is not a database in > "select count() from sqlite_master;" error 13:43:10.040329 +0800 salesApp file is not a database in > "create table 'globalData' ( _id INTEGER primary key autoincrement, > 'globalid' TEXT, json BLOB, _dirty REAL default 0, _deleted INTEGER default 0, _operation TEXT);" error 13:43:11.167875 +0800 salesApp file is not a database in > "select count() from sqlite_master;" error 13:43:11.168313 +0800 salesApp file is not a database in > "create table 'globalData' ( _id INTEGER primary key autoincrement, '_id' > REAL, 'globalid' TEXT, json BLOB, _dirty REAL default 0, _deleted > INTEGER default 0, _operation TEXT);"

Really appreciate your feedback, thank you very much..

1

There are 1 answers

2
SSuman99 On BEST ANSWER

Check if you have sqlite library linked to your project. If yes either remove it or move it down , after sqlcipher.framework in Linking phase of xcode project.