function liveFeed_update() {
//var num_row = 0;
var _scripPromise = new Promise(function(resolve, reject) {
var query_01 = "SELECT count (*) as total FROM livedata where
script_name = 'ABC'
";
con.query(query_01).then(function(response) {
resolve(response);
console.log(response); //end of resolve
}) //end of then
.catch(function(error) {
reject(error);
console.log(error);
}) //end of catch
});
_scripPromise.then(function(message) {
console.log(message);
},
function(err) {
console.log(err);
}
);
}
请帮助我解决此错误。
我得到这个:
"TypeError: con.query(...).then is not a function"