I'm trying to add some data to my table, but I keep getting a error, I can't understand which part is invalid in there?
var sql = "INSERT INTO `coinflips` (opponent, opponent_side, opponent_items) VALUES ? WHERE gameid=??";
var value = [
[data.steamid, data.side, items, gameID]
];
connection.query(sql, [value], function(err){
if(err) throw err;
});
Error itself
Error: ER_PARSE_ERROR: You have an error in your SQL syntax; check the manual th at corresponds to your MariaDB server version for the right syntax to use near ' WHERE gameid=??' at line 1
via James Aniszt
No comments:
Post a Comment