You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
What is the feature you are proposing to solve the problem?
Being able to do a query like this, where parameters to an IN operator in the WHERE clause can be substituted by an array of values:
const stmt = conn.prepare(`select name from people where id in (?)`);
res = stmt.get([100,200,300])
What alternatives have you considered?
Only the workaround in the above linked Stackoverflow question, where you have to make provision for each value individually in the query (which would require a new prepared statement each time):
const values = [100,200,300];
// 3 values, so need 3 params: ?,?,?
const params = values.map(_=>'?').join(',');
const stmt = conn.prepare(`select name from people where id in (${params})`);
res = stmt.get(values);
The text was updated successfully, but these errors were encountered:
What is the problem this feature will solve?
Being able to use the SQL IN operator is not possible without a workaround; see https://stackoverflow.com/questions/79441096/using-sql-in-operator-with-databasesync-in-node-sqlite
What is the feature you are proposing to solve the problem?
Being able to do a query like this, where parameters to an IN operator in the WHERE clause can be substituted by an array of values:
What alternatives have you considered?
Only the workaround in the above linked Stackoverflow question, where you have to make provision for each value individually in the query (which would require a new prepared statement each time):
The text was updated successfully, but these errors were encountered: