Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- {
- cars: [
- {
- manufacturer: "Ford",
- model: "F-150",
- color: "blue",
- year: 2002
- },
- {
- manufacturer: "Dodge",
- model: "Durango",
- color: "red",
- year: 1998
- },
- {
- manufacturer: "Honda",
- model: "Accord",
- color: "silver",
- year: 2015
- },
- // and so on
- ]
- }
- db.query(
- "INSERT INTO vehicles SET ? ON DUPLICATE UPDATE color=VALUE(color), year=VALUE(year)",
- vehicleObject,
- function (error, response) {
- if (error) throw error;
- }
- );
- Error: ER_PARSE_ERROR: You have an error in your SQL syntax; check the
- manual that corresponds to your MariaDB server version for the right syntax
- to use near ''[object Object]', '[object Object]', '[object Object]',
- '[object Object]', '[ob' at line 1
Add Comment
Please, Sign In to add comment