Skip to content
RED SAGSkills
easy5 pts · first answer countssecuritysql

Stopping SQL injection

This login code builds SQL by joining strings with user input. What is the correct way to prevent SQL injection?

const sql = "SELECT * FROM users WHERE email = '" + email + "'"
await db.query(sql)
Choose one answer