SQLite错误:无效的数据库句柄

时间:2018-06-27 08:29:34

标签: javascript sqlite cordova cordova-sqlite-storage

我正在开发一个cordova应用程序,该应用程序似乎可以在 debug 模式(Windows-x86)平台上工作。

我们在移动应用程序中使用 cordova-sqlite-storage 插件

但是,每当我切换到 release 模式时,以下两种配置均无效:

  • Windows-x86
  • Windows-x64(调试和发布模式)

我逐步浏览了我们的应用程序,发现它卡在执行sqlite transaction 方法上。

_localDb.transaction(function(trans) {
        trans.executeSql("CREATE TABLE IF NOT EXISTS DeviceData (Data)", [], function () {
            WriteConsoleLog("DbCreateDatabaseForDevice completed. " + databaseName, "success");
            if (callback !== undefined && callback !== null) callback();
        });
    }, function (error) { //Added error handling method
        var a = error;
    });

我已在该特定行中添加了错误处理功能,以查看插件返回的错误消息。

outerHTML

Here are the results when stepping through debug mode

我正在使用:

  • Visual Studio 2015专业更新3
  • 科尔多瓦6.5.0
  • Cordova Sqlite存储插件2.0.2

0 个答案:

没有答案