Controller Code
app.post('/savedata', function(req, res) {
var cope = req.body;
console.log("On server side");
console.log(cope.Client_ID);
var queries =
connection.query('update lv_billing.client SET Client_ID = ?, Client_Name = ?,Status = ?,Updt_Time = ?,Updt_By = ?,Updt_ID = ?,Cluster = ? where Client_ID = ?',cope.Client_ID,cope.Client_Name,cope.Status,cope.Updt_Time,cope.Updt_By,cope.Updt_ID,cope.Cluster,cope.Client_ID, function(err,res){
if(err) throw err;
console.log('Inserted!');
})
});
The above code is throwing the error "this._callback.apply" is not even a function. To set a little context. i m trying to update my table with the new values from the array. 'cope' is an array which holds values which needs to be updated.