I want to return my 'result' variable to the main function (geometryFromDatabase) but I have no idea how to do it. I have function like following:
function geometryFromDatabase() {
  var db = $window.sqlitePlugin.openDatabase({name:sqlite}, function () {
    db.transaction(function (tx) {
      tx.executeSql("select st_asText(geo_coord_) from referenzfb where id=676919;", [], function (tx, result) {
        return result;
      });
    });
  });
}
 
    