I have a problem to send a mysql query where this problem :ER_PARSE_ERROR: You have an error in your SQL syntax appears, my code where user is an javascript object contains 3 strings username,email,password .
let sql2 = 'insert into users (username,email,password) values (' + user.username + ',' + user.email + ',' + user.password + ')' //query
db.query(sql2,(err,result) => {
if(err) throw err
res.send('User registriation done')
})
let sql = 'select email from users where email = ?'and then passuser.emailin the parameter arraay.