Adding a row with multiple columns using Node.js & sqllite3 Adding a row with multiple columns using Node.js & sqllite3 express express

Adding a row with multiple columns using Node.js & sqllite3


Parameter of db.run should have been passed as an array when using multiple placeholders instead of a string. Solution:

db.run('INSERT INTO users VALUES(?, ?)', ['John', 'Doe'])db.close();